aboutsummaryrefslogtreecommitdiff
path: root/lib/ftp.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ftp.c')
-rw-r--r--lib/ftp.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index b78617e75..422bac219 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -3185,6 +3185,7 @@ static CURLcode ftp_done(struct connectdata *conn, CURLcode status,
ftpc->cwdfail = TRUE; /* set this TRUE to prevent us to remember the
current path, as this connection is going */
conn->bits.close = TRUE; /* marked for closure */
+ result = status; /* use the already set error code */
break;
}