aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/ftp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/ftp.c b/lib/ftp.c
index 0e75a424d..5282204a7 100644
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -3214,7 +3214,8 @@ static CURLcode ftp_done(struct connectdata *conn, CURLcode status,
ftpc->prevpath=strdup("");
free(path);
}
- infof(data, "Remembering we are in dir \"%s\"\n", ftpc->prevpath);
+ if(ftpc->prevpath)
+ infof(data, "Remembering we are in dir \"%s\"\n", ftpc->prevpath);
}
else {
ftpc->prevpath = NULL; /* no path */