[3/7] msi: Don't create a temporary copy of the package. (try 2)

Octavian Voicu octavian.voicu at gmail.com
Tue Aug 23 09:50:02 CDT 2011

On Tue, Aug 23, 2011 at 3:13 PM, Joris Huizer <joris_huizer at yahoo.com>wrote:

> On 08/23/2011 11:45 AM, Hans Leidekker wrote:
>> +    if (!strcmpiW( package, unsquashed ))
> I'm confused about the last part of the function.
> I think if the comparison between 'package' and 'unsquashed' fails, you
> want to return an error,
> but the return value 'r' will be ERROR_SUCCESS at that point, and isn't
> updated.


The function strcmpiW returns 0 when the strings are equal, and non-zero
when they are different (< 0 if first is smaller, > 0 if first is larger,
lexicographically speaking). The condition checks if the strings match, not
if the function failed (string comparison cannot "fail").

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20110823/5c8bf333/attachment.htm>

More information about the wine-devel mailing list