https://bugs.winehq.org/show_bug.cgi?id=50951
Bug ID: 50951 Summary: Possible Crash because of wrong initialization of struct COMBOBOXEXITEM Product: Wine Version: 6.5 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: api-ms-win-* Assignee: wine-bugs@winehq.org Reporter: taxpool@protonmail.ch Distribution: ---
//BUG #1: cchTextMax member of COMBOBOXEXITEM is always 0 (in Windows 260) //BUG #2: Text can't be copied to pszText
void CMyCombo::GetCBDispString(NMHDR* pNMHDR, LRESULT* pResult) { NMCOMBOBOXEX* pncbe = reinterpret_cast<NMCOMBOBOXEX*>(pNMHDR); COMBOBOXEXITEM& cbei = pncbe->ceItem; if (cbei.mask & CBEIF_TEXT) { //strcpy(cbei.pszText, "xxx"); //CRASH cbei.pszText = "xxx"; //WORKS
//cbei.mask |= CBEIF_DI_SETITEM; }
*pResult = 0; }
https://bugs.winehq.org/show_bug.cgi?id=50951
--- Comment #1 from Nikolay Sivov bunglehead@gmail.com --- Hi,
Please attach complete test program that shows the issue.
https://bugs.winehq.org/show_bug.cgi?id=50951
Nikolay Sivov bunglehead@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|api-ms-win-* |-unknown
https://bugs.winehq.org/show_bug.cgi?id=50951
--- Comment #2 from taxpool taxpool@protonmail.ch --- Created attachment 69780 --> https://bugs.winehq.org/attachment.cgi?id=69780 Visual Studio Test Project
https://bugs.winehq.org/show_bug.cgi?id=50951
--- Comment #3 from taxpool taxpool@protonmail.ch --- Created attachment 69781 --> https://bugs.winehq.org/attachment.cgi?id=69781 Sample .exe (64 Bit, static lib, multibyte)
https://bugs.winehq.org/show_bug.cgi?id=50951
Nikolay Sivov bunglehead@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|-unknown |comctl32
--- Comment #4 from Nikolay Sivov bunglehead@gmail.com --- Thank you, I'll do some tests.