Skip to content

Commit

Permalink
noproxy: pointer to local array 'hostip' is stored outside scope
Browse files Browse the repository at this point in the history
Ref: #10929
Closes #10933
  • Loading branch information
bagder committed Apr 12, 2023
1 parent dd81304 commit ca05e1a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/noproxy.c
Expand Up @@ -122,6 +122,7 @@ enum nametype {
bool Curl_check_noproxy(const char *name, const char *no_proxy,
bool *spacesep)
{
char hostip[128];
*spacesep = FALSE;
/*
* If we don't have a hostname at all, like for example with a FILE
Expand All @@ -139,7 +140,6 @@ bool Curl_check_noproxy(const char *name, const char *no_proxy,
const char *p = no_proxy;
size_t namelen;
enum nametype type = TYPE_HOST;
char hostip[128];
if(!strcmp("*", no_proxy))
return TRUE;

Expand Down

0 comments on commit ca05e1a

Please sign in to comment.