aboutsummaryrefslogtreecommitdiff
path: root/docs/examples/ftpsget.c
diff options
context:
space:
mode:
Diffstat (limited to 'docs/examples/ftpsget.c')
-rw-r--r--docs/examples/ftpsget.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/examples/ftpsget.c b/docs/examples/ftpsget.c
index dbe7d14bf..dfe80b9f8 100644
--- a/docs/examples/ftpsget.c
+++ b/docs/examples/ftpsget.c
@@ -44,7 +44,7 @@ static size_t my_fwrite(void *buffer, size_t size, size_t nmemb,
/* open file for writing */
out->stream = fopen(out->filename, "wb");
if(!out->stream)
- return -1; /* failure, cannot open file to write */
+ return 0; /* failure, cannot open file to write */
}
return fwrite(buffer, size, nmemb, out->stream);
}