From: Wayne Davison Date: Fri, 8 Dec 2006 21:02:11 +0000 (+0000) Subject: Explicitly cast the length values down to an uint32 so that some X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/commitdiff_plain/60af946576ba43a94d7adea0ff3b5ef5e9e28e09 Explicitly cast the length values down to an uint32 so that some compilers don't complain about the value getting smaller. --- diff --git a/flist.c b/flist.c index 3e4f6bf9..04fecb6f 100644 --- a/flist.c +++ b/flist.c @@ -644,7 +644,7 @@ static struct file_struct *recv_file_entry(struct file_list *flist, file->flags |= FLAG_HLINKED; #endif file->modtime = modtime; - file->len32 = file_length; + file->len32 = (uint32)file_length; if (file_length > 0xFFFFFFFFu && S_ISREG(mode)) { file->flags |= FLAG_LENGTH64; OPT_EXTRA(file, 0)->unum = (uint32)(file_length >> 32); @@ -921,7 +921,7 @@ struct file_struct *make_file(const char *fname, struct file_list *flist, file->flags = flags; file->modtime = st.st_mtime; - file->len32 = st.st_size; + file->len32 = (uint32)st.st_size; if (st.st_size > 0xFFFFFFFFu && S_ISREG(st.st_mode)) { file->flags |= FLAG_LENGTH64; OPT_EXTRA(file, 0)->unum = (uint32)(st.st_size >> 32);