diff options
author | Marcel Raad <Marcel.Raad@teamviewer.com> | 2021-02-06 11:40:18 +0100 |
---|---|---|
committer | Marcel Raad <Marcel.Raad@teamviewer.com> | 2021-02-10 16:47:15 +0100 |
commit | fa624f0baa4e1350546c31b54a5942f493de7dd3 (patch) | |
tree | c40a6f471a881be3634adb34b4ceaef3c0ac0bf6 | |
parent | 4c02d003ff581166d8adf43cd1606eaa4ace945d (diff) | |
download | curl-fa624f0baa4e1350546c31b54a5942f493de7dd3.tar.gz |
tool_paramhlp: reduce variable scope
Closes https://github.com/curl/curl/pull/6576
-rw-r--r-- | src/tool_paramhlp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tool_paramhlp.c b/src/tool_paramhlp.c index 461474644..49deb0929 100644 --- a/src/tool_paramhlp.c +++ b/src/tool_paramhlp.c @@ -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; |