aboutsummaryrefslogtreecommitdiff
path: root/docs/examples/ftp-wildcard.c
diff options
context:
space:
mode:
authorMarcel Raad <Marcel.Raad@teamviewer.com>2019-05-25 10:06:08 +0200
committerMarcel Raad <Marcel.Raad@teamviewer.com>2019-06-05 20:38:06 +0200
commite23c52b3295a525fbaae9e7ed3e7061fea6dffc2 (patch)
tree4a74cf5ed3496a6126f1cc7c4284b6620108db06 /docs/examples/ftp-wildcard.c
parent04ac54e1965041684fc1b6532eba90f58601264e (diff)
build: fix Codacy warnings
Reduce variable scopes and remove redundant variable stores. Closes https://github.com/curl/curl/pull/3975
Diffstat (limited to 'docs/examples/ftp-wildcard.c')
-rw-r--r--docs/examples/ftp-wildcard.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/docs/examples/ftp-wildcard.c b/docs/examples/ftp-wildcard.c
index f249bc135..ee815973d 100644
--- a/docs/examples/ftp-wildcard.c
+++ b/docs/examples/ftp-wildcard.c
@@ -41,8 +41,6 @@ static size_t write_it(char *buff, size_t size, size_t nmemb,
int main(int argc, char **argv)
{
- int rc = CURLE_OK;
-
/* curl easy handle */
CURL *handle;
@@ -50,7 +48,7 @@ int main(int argc, char **argv)
struct callback_data data = { 0 };
/* global initialization */
- rc = curl_global_init(CURL_GLOBAL_ALL);
+ int rc = curl_global_init(CURL_GLOBAL_ALL);
if(rc)
return rc;