다음을 통해 공유


PREfast Warning 311 (Windows CE 5.0)

Send Feedback

311 - Consider using <function> instead of <function>.

This message suggests a preferred function call that that might be semantically equivalent to the existing function call.

Example

Defective Source

char buff[MAX_PATH];

OemToChar(buff, input);  // if strlen(input) > MAX_PATH,
                         // leads to buffer overrun.

Corrected Source

char buff[MAX_PATH];

OemToCharBuff(buff, input, MAX_PATH);

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.