Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic


warning C6329: Return value for a call to <function> should not be checked against <number>

The program is comparing a number against the return value from a call to CreateFile. If CreateFile succeeds, it returns an open handle to the object. If it fails, it returns INVALID_HANDLE_VALUE.

This code could cause the warning:

if (CreateFile() == NULL)

This code corrects the error:

if (CreateFile() == INVALID_HANDLE_VALUE)
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
© 2014 Microsoft. All rights reserved.