diff options
Diffstat (limited to 'libarchive/archive_read_disk_posix.c')
-rw-r--r-- | libarchive/archive_read_disk_posix.c | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/libarchive/archive_read_disk_posix.c b/libarchive/archive_read_disk_posix.c index 52fec7bb42c8..2898206951d5 100644 --- a/libarchive/archive_read_disk_posix.c +++ b/libarchive/archive_read_disk_posix.c @@ -1658,7 +1658,7 @@ static int setup_current_filesystem(struct archive_read_disk *a) { struct tree *t = a->tree; - struct statvfs sfs; + struct statvfs svfs; int r, xr = 0; t->current_filesystem->synthetic = -1; @@ -1667,16 +1667,16 @@ setup_current_filesystem(struct archive_read_disk *a) return (ARCHIVE_FAILED); } if (tree_current_is_symblic_link_target(t)) { - r = statvfs(tree_current_access_path(t), &sfs); + r = statvfs(tree_current_access_path(t), &svfs); if (r == 0) xr = get_xfer_size(t, -1, tree_current_access_path(t)); } else { #ifdef HAVE_FSTATVFS - r = fstatvfs(tree_current_dir_fd(t), &sfs); + r = fstatvfs(tree_current_dir_fd(t), &svfs); if (r == 0) xr = get_xfer_size(t, tree_current_dir_fd(t), NULL); #else - r = statvfs(".", &sfs); + r = statvfs(".", &svfs); if (r == 0) xr = get_xfer_size(t, -1, "."); #endif @@ -1688,30 +1688,30 @@ setup_current_filesystem(struct archive_read_disk *a) } else if (xr == 1) { /* Usually come here unless NetBSD supports _PC_REC_XFER_ALIGN * for pathconf() function. */ - t->current_filesystem->xfer_align = sfs.f_frsize; + t->current_filesystem->xfer_align = svfs.f_frsize; t->current_filesystem->max_xfer_size = -1; #if defined(HAVE_STRUCT_STATVFS_F_IOSIZE) - t->current_filesystem->min_xfer_size = sfs.f_iosize; - t->current_filesystem->incr_xfer_size = sfs.f_iosize; + t->current_filesystem->min_xfer_size = svfs.f_iosize; + t->current_filesystem->incr_xfer_size = svfs.f_iosize; #else - t->current_filesystem->min_xfer_size = sfs.f_bsize; - t->current_filesystem->incr_xfer_size = sfs.f_bsize; + t->current_filesystem->min_xfer_size = svfs.f_bsize; + t->current_filesystem->incr_xfer_size = svfs.f_bsize; #endif } - if (sfs.f_flag & ST_LOCAL) + if (svfs.f_flag & ST_LOCAL) t->current_filesystem->remote = 0; else t->current_filesystem->remote = 1; #if defined(ST_NOATIME) - if (sfs.f_flag & ST_NOATIME) + if (svfs.f_flag & ST_NOATIME) t->current_filesystem->noatime = 1; else #endif t->current_filesystem->noatime = 0; /* Set maximum filename length. */ - t->current_filesystem->name_max = sfs.f_namemax; + t->current_filesystem->name_max = svfs.f_namemax; return (ARCHIVE_OK); } @@ -1840,7 +1840,7 @@ setup_current_filesystem(struct archive_read_disk *a) #if defined(HAVE_STATVFS) if (svfs.f_flag & ST_NOATIME) #else - if (sfs.f_flag & ST_NOATIME) + if (sfs.f_flags & ST_NOATIME) #endif t->current_filesystem->noatime = 1; else @@ -1864,7 +1864,7 @@ static int setup_current_filesystem(struct archive_read_disk *a) { struct tree *t = a->tree; - struct statvfs sfs; + struct statvfs svfs; int r, xr = 0; t->current_filesystem->synthetic = -1;/* Not supported */ @@ -1883,7 +1883,7 @@ setup_current_filesystem(struct archive_read_disk *a) "openat failed"); return (ARCHIVE_FAILED); } - r = fstatvfs(fd, &sfs); + r = fstatvfs(fd, &svfs); if (r == 0) xr = get_xfer_size(t, fd, NULL); close(fd); @@ -1892,13 +1892,13 @@ setup_current_filesystem(struct archive_read_disk *a) archive_set_error(&a->archive, errno, "fchdir failed"); return (ARCHIVE_FAILED); } - r = statvfs(tree_current_access_path(t), &sfs); + r = statvfs(tree_current_access_path(t), &svfs); if (r == 0) xr = get_xfer_size(t, -1, tree_current_access_path(t)); #endif } else { #ifdef HAVE_FSTATVFS - r = fstatvfs(tree_current_dir_fd(t), &sfs); + r = fstatvfs(tree_current_dir_fd(t), &svfs); if (r == 0) xr = get_xfer_size(t, tree_current_dir_fd(t), NULL); #else @@ -1906,7 +1906,7 @@ setup_current_filesystem(struct archive_read_disk *a) archive_set_error(&a->archive, errno, "fchdir failed"); return (ARCHIVE_FAILED); } - r = statvfs(".", &sfs); + r = statvfs(".", &svfs); if (r == 0) xr = get_xfer_size(t, -1, "."); #endif @@ -1918,14 +1918,14 @@ setup_current_filesystem(struct archive_read_disk *a) return (ARCHIVE_FAILED); } else if (xr == 1) { /* pathconf(_PC_REX_*) operations are not supported. */ - t->current_filesystem->xfer_align = sfs.f_frsize; + t->current_filesystem->xfer_align = svfs.f_frsize; t->current_filesystem->max_xfer_size = -1; - t->current_filesystem->min_xfer_size = sfs.f_bsize; - t->current_filesystem->incr_xfer_size = sfs.f_bsize; + t->current_filesystem->min_xfer_size = svfs.f_bsize; + t->current_filesystem->incr_xfer_size = svfs.f_bsize; } #if defined(ST_NOATIME) - if (sfs.f_flag & ST_NOATIME) + if (svfs.f_flag & ST_NOATIME) t->current_filesystem->noatime = 1; else #endif @@ -1933,7 +1933,7 @@ setup_current_filesystem(struct archive_read_disk *a) #if defined(USE_READDIR_R) /* Set maximum filename length. */ - t->current_filesystem->name_max = sfs.f_namemax; + t->current_filesystem->name_max = svfs.f_namemax; #endif return (ARCHIVE_OK); } |