1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-10 01:48:00 +00:00

uxsftpserver: cast st.st_size to uintmax_t.

This fixes a build failure reported by Colin on platforms (armel,
mipsel) where off_t and PRIu64 don't match.
This commit is contained in:
Simon Tatham 2019-02-07 20:06:55 +00:00
parent 85eaaa86b7
commit 8ccbd164c7

View File

@ -650,8 +650,9 @@ static void uss_readdir(SftpServer *srv, SftpReplyBuilder *reply,
tm = *localtime(&st.st_mtime);
longnamebuf = dupprintf(
"%s %3u %-8s %-8s %8"PRIu64" %.3s %2d %02d:%02d %s",
perms, (unsigned)st.st_nlink, user, group, st.st_size,
"%s %3u %-8s %-8s %8"PRIuMAX" %.3s %2d %02d:%02d %s",
perms, (unsigned)st.st_nlink, user, group,
(uintmax_t)st.st_size,
(&"JanFebMarAprMayJunJulAugSepOctNovDec"[3*tm.tm_mon]),
tm.tm_mday, tm.tm_hour, tm.tm_min, de->d_name);
longname = ptrlen_from_asciz(longnamebuf);