diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ssh.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -1442,6 +1442,11 @@ static CURLcode ssh_statemach_act(struct connectdata *conn, bool *block) data->state.resume_from = 0; } else { + curl_off_t size = attrs.filesize; + if(size < 0) { + failf(data, "Bad file size (%" FORMAT_OFF_T ")", size); + return CURLE_BAD_DOWNLOAD_RESUME; + } data->state.resume_from = attrs.filesize; } } |