Dylan Smith <dylan.ah.smith(a)gmail.com> wrote:
+ wcexA.cbSize = 0; + wcexA.style = cls.style; + wcexA.lpfnWndProc = cls.lpfnWndProc; + wcexA.cbClsExtra = cls.cbClsExtra; + wcexA.cbWndExtra = cls.cbWndExtra; + wcexA.hInstance = cls.hInstance; + wcexA.hIcon = cls.hIcon; + wcexA.hCursor = cls.hCursor; + wcexA.hbrBackground = cls.hbrBackground; + wcexA.lpszMenuName = cls.lpszMenuName; + wcexA.lpszClassName = cls.lpszClassName; + wcexA.hIconSm = 0; + ok( ((RegisterClassExA( &wcexA ) == 0) && (GetLastError() == ERROR_INVALID_PARAMETER)), + "Failed with invalid number of cbSize bytes\n");
Testing other values besides 0 would be helpful, in particular values like sizeof(class) - 1 and sizeof(class) + 1. Did you inspect all the places in Wine which call RegisterClassEx()? Also, GetClassInfoEx() in Wine is an obvious offender, and this needs a test (and a fix) too. -- Dmitry.