http://bugs.winehq.org/show_bug.cgi?id=16418
--- Comment #28 from Louis Lenders xerox_xerox2000@yahoo.co.uk 2010-03-28 16:38:50 --- Created an attachment (id=27085) --> (http://bugs.winehq.org/attachment.cgi?id=27085) test whether or not the looked up names are null-terminated
I think i now have pinpointed the problem. MSDN states that the looked up names may or may not be NULL-terminated. In our code for LsaLookUpSids, LookUpAccountSid is called and that always delivers a null-terminated string, so LsaLookUpSids does so too, and the maximumlength and length are always equal in wine's code.
The attached tests show what names on windows are null terminated and which not (only tested a few), so we have to deal with this and distinguish between these , as this bug depends on this.