[Bug 22514] lstrlen is implemented incorrectly (dlls/kernel32/string.c)
wine-bugs at winehq.org
wine-bugs at winehq.org
Thu Apr 29 10:32:16 CDT 2010
http://bugs.winehq.org/show_bug.cgi?id=22514
--- Comment #28 from Dmitry Timoshkov <dmitry at codeweavers.com> 2010-04-29 10:32:16 ---
(In reply to comment #26)
> They don't pass NULL to strlen in Chromium.
strlen() functionally is equivalent of lstrlen(), with only exception of
internal handling of invalid pointers.
> They pass NULL only to lstrlen in windows-specific code and expect 0 in this
> case. They don't try to pass invalid non-NULL pointers.
> I doubt they would accept additional "if()" branches to make Wine+Valgrind
> happy. After all, they use the documented features of lstrlen and they do it
> correctly.
NULL pointer is invalid by definition. Passing it to lstrlen() should crash,
but Microsoft did a favour to broken application and added an exception
handler.
Claiming that an app uses documented way of passing NULL to lstrlen() and
expects
it to return 0 is confusing.
--
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
Do not reply to this email, post in Bugzilla using the
above URL to reply.
------- You are receiving this mail because: -------
You are watching all bug changes.
More information about the wine-bugs
mailing list