if ( aResult ) { nsNativeAppSupportWin *pNative = new nsNativeAppSupportWin; if ( pNative ) { *aResult = pNative; NS_ADDREF( *aResult );  pNative->CheckConsole(); } else { return NS_ERROR_OUT_OF_MEMORY; } } else { return NS_ERROR_NULL_POINTER; }
nsNativeAppSupportWin *pNative = new nsNativeAppSupportWin; if (!pNative) return NS_ERROR_OUT_OF_MEMORY;   pNative->CheckConsole();  *aResult = pNative; NS_ADDREF( *aResult );
NS_CreateNativeAppSupport( nsINativeAppSupport **aResult ) {    if ( aResult ) {        nsNativeAppSupportWin *pNative = new nsNativeAppSupportWin;        if ( pNative ) {            *aResult = pNative;            NS_ADDREF( *aResult );            // Check for dynamic console creation request.            pNative->CheckConsole();        } else {            return NS_ERROR_OUT_OF_MEMORY;        }    } else {        return NS_ERROR_NULL_POINTER;    }    return NS_OK;}