The information in this article applies to:
SYMPTOMSExplicitly referencing the Null character in the second argument of strcmp causes the intrinsic version of strcmp to incorrectly report the two arguments are not equal. Please see the sample code below. RESOLUTION
Use one of the following two workarounds:
STATUSMicrosoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. MORE INFORMATION
You can enable intrinsic functions either by using of the /Oi compiler
switch or #pragma intrinsic. To disable intrinsic functions, remove the /Oi
compiler switch, add /Oi-, or use #pragma function to force a function call
on a function by function basis. Please see the sample code below for use
of the #pragma function.
Sample Code
Note that a more common use of an embedded Null character may be to compare
a string to "\0" to see if it is an empty string. For the first workaround above,
compare it to "" instead.
Additional query words:
Keywords : kbcode kbprg kbVC500bug kbVC600bug |
Last Reviewed: March 14, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |