C6102

 

The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.

The latest version of this topic can be found at C6102.

warning C6102: Using <variable> from failed function call at line <location>.

This warning is reported instead of C6001 when a variable is not set because it was marked as an _Out_ parameter on a prior function call that failed.

The problem might be that the prior called function is not completely annotated. It may require _Always_, _Outptr_result_nullonfailure_ (_COM_Outptr_ for COM code), or a related annotation.

C6001
Using SAL Annotations to Reduce C/C++ Code Defects

Show: