[Coverity 1666173] Use after free in sftp.c
This could cause an immediate crash or incorrect values might be read subsequently resulting in incorrect computations.
In Open: A pointer to freed memory is dereferenced, used as a function argument, or otherwise used (CWE-416)
449 if( strstr( psz_userauthlist, "publickey" ) != NULL && !b_publickey_tried )
450 {
451 /* Don't try public key multiple times to avoid getting black
452 * listed */
453 b_publickey_tried = true;
38. Condition AuthKeyAgent(p_access, credential.psz_username) == 0, taking false branch.
CID 1666173: (#1 of 1): Use after free (USE_AFTER_FREE)
39. pass_freed_arg: Passing freed pointer psz_home as an argument to AuthPublicKey.
454 if( AuthKeyAgent( p_access, credential.psz_username ) == VLC_SUCCESS
455 || AuthPublicKey( p_access, psz_home, credential.psz_username ) == VLC_SUCCESS )
456 break;
457 }
Check missing after df1ee8c9