Tab Controls without name

Vincent Béron vberon at
Wed Sep 4 10:05:59 CDT 2002

Le mer 04/09/2002 à 10:51, Fabian Cenedese a écrit :
> Hi
> I found something that would be easy to fix in case it really should be 
> fixed. Working with tab controls I have the case where I set the tab name 
> to empty because it's too big to be shown. In the TCITEM structure I set 
> the text pointer to NULL instead of a "". Thus Wine stopped at some point 
> doing a strlen on a NULL pointer. Obvious. Then I checked MSDN if this is 
> allowed or not. It always says string pointer, never is a NULL pointer a 
> possible value. Ok, so my code is wrong, easy to change.
> But still (the often cited sentence): It used to work in Windows. So now I 
> don't know if Wine should be clean (and NULL pointer in tab name is not 
> allowed) or if it should behave as Windows (no matter what docs say) and a 
> NULL pointer is just an empty name...

What we did for previous problems of that kind is to allow it to be NULL
(thus add some checks) if we know of an app that uses it.

The first implementation should always follow what MSDN says (except if
it's a partial implementation, of course). If it is found that Windows
acts differently than MSDN says, and that an app in the wild is actually
expecting that behaviour, then we add some NULL checks to refrain Wine
from crashing (more precisely, to act as Windows does).

Besides your own app, do you know of another app which uses that

(Somebody correct me if I'm talking out of my a**)


More information about the wine-devel mailing list