← Commit list

c049c37acd

Daniel Stenberg
Daniel Stenberg
2025-10-10
SUCCESS Duration: 291s

Subject

libssh: make atime and mtime cap the timestamp instead of wrap

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

lib/vssh/libssh.c+3 -0
@@ -1864,6 +1864,9 @@ static int myssh_in_SFTP_QUOTE_STAT(struct Curl_easy *data,
sshc->actualcode = CURLE_QUOTE_ERROR;
return SSH_NO_ERROR;
}
+ if(date > UINT_MAX)
+ /* because the liubssh API can't deal with a larger value */
+ date = UINT_MAX;
if(!strncmp(cmd, "atime", 5))
sshc->quote_attrs->atime = (uint32_t)date;
else /* mtime */