diff options
author | Daniel Stenberg <daniel@haxx.se> | 2000-11-17 15:32:17 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2000-11-17 15:32:17 +0000 |
commit | 0a72154cd2422024c5e77762761fc101d47c4faf (patch) | |
tree | bac5a3dc2d591c2c08ed106bb185612affec5f20 /src | |
parent | 3e6a354c4c7e9ff0bccd43221713bbf327d4670f (diff) | |
download | curl-0a72154cd2422024c5e77762761fc101d47c4faf.tar.gz |
fixed strdup() of a NULL pointer
Diffstat (limited to 'src')
-rw-r--r-- | src/main.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/main.c b/src/main.c index f8a2a0422..b8e6875b9 100644 --- a/src/main.c +++ b/src/main.c @@ -365,7 +365,6 @@ static char *my_get_token(const char *line); static void GetStr(char **string, char *value) { - fprintf(stderr, "called\n"); if(*string) free(*string); if(value && *value) @@ -1404,7 +1403,7 @@ int main(int argc, char *argv[]) return res; /* save outfile pattern befor expansion */ - outfiles = strdup(config.outfile); + outfiles = config.outfile?strdup(config.outfile):NULL; if (!outfiles && !config.remotefile && urlnum > 1) { #ifdef CURL_SEPARATORS |