1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-23 16:48:49 -05:00

tool_paramhlp: reduce variable scope

Closes https://github.com/curl/curl/pull/6576
This commit is contained in:
Marcel Raad 2021-02-06 11:40:18 +01:00
parent 4c02d003ff
commit fa624f0baa
No known key found for this signature in database
GPG Key ID: 33C416EFAE4D6F02

View File

@ -40,10 +40,11 @@
struct getout *new_getout(struct OperationConfig *config)
{
static int outnum = 0;
struct getout *node = calloc(1, sizeof(struct getout));
struct getout *last = config->url_last;
if(node) {
static int outnum = 0;
/* append this new node last in the list */
if(last)
last->next = node;