mirror of
https://github.com/moparisthebest/curl
synced 2024-12-23 00:28:48 -05:00
check the correct variable to want about --stderr failures properly
CID 18 by the coverity.com scan
This commit is contained in:
parent
5796c7b132
commit
9d8b22d3de
@ -1769,7 +1769,7 @@ static ParameterError getparameter(char *flag, /* f or -long-flag */
|
||||
case 'v': /* --stderr */
|
||||
if(strcmp(nextarg, "-")) {
|
||||
FILE *newfile = fopen(nextarg, "wt");
|
||||
if(!config->errors)
|
||||
if(!newfile)
|
||||
warnf(config, "Failed to open %s!\n", nextarg);
|
||||
else {
|
||||
config->errors = newfile;
|
||||
|
Loading…
Reference in New Issue
Block a user