mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-09 09:54:25 +09:00
Fix compile warnings.
git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@276 7dcaeef0-15fb-0310-b436-a5af3365683c
This commit is contained in:
@@ -648,7 +648,9 @@ static SFTP_ATTRIBUTES *sftp_parse_attr_3(SFTP_SESSION *sftp, BUFFER *buf,
|
|||||||
if(buffer_get_u64(buf,&attr->size)!=sizeof(u64))
|
if(buffer_get_u64(buf,&attr->size)!=sizeof(u64))
|
||||||
break;
|
break;
|
||||||
attr->size=ntohll(attr->size);
|
attr->size=ntohll(attr->size);
|
||||||
ssh_log(sftp->session, SSH_LOG_RARE, "Size: %lu\n", attr->size);
|
ssh_log(sftp->session, SSH_LOG_RARE,
|
||||||
|
"Size: %llu\n",
|
||||||
|
(long long unsigned int) attr->size);
|
||||||
}
|
}
|
||||||
if(flags & SSH_FILEXFER_ATTR_UIDGID){
|
if(flags & SSH_FILEXFER_ATTR_UIDGID){
|
||||||
if(buffer_get_u32(buf,&attr->uid)!=sizeof(u32))
|
if(buffer_get_u32(buf,&attr->uid)!=sizeof(u32))
|
||||||
|
|||||||
8
sample.c
8
sample.c
@@ -301,8 +301,12 @@ void do_sftp(SSH_SESSION *session){
|
|||||||
}
|
}
|
||||||
/* reading the whole directory, file by file */
|
/* reading the whole directory, file by file */
|
||||||
while((file=sftp_readdir(sftp,dir))){
|
while((file=sftp_readdir(sftp,dir))){
|
||||||
fprintf(stderr, "%30s(%.8o) : %.5d.%.5d : %.10ld bytes\n",
|
fprintf(stderr, "%30s(%.8o) : %.5d.%.5d : %.10llu bytes\n",
|
||||||
file->name, file->permissions, file->uid, file->gid, file->size);
|
file->name,
|
||||||
|
file->permissions,
|
||||||
|
file->uid,
|
||||||
|
file->gid,
|
||||||
|
(long long unsigned int) file->size);
|
||||||
sftp_attributes_free(file);
|
sftp_attributes_free(file);
|
||||||
}
|
}
|
||||||
/* when file=NULL, an error has occured OR the directory listing is end of file */
|
/* when file=NULL, an error has occured OR the directory listing is end of file */
|
||||||
|
|||||||
Reference in New Issue
Block a user