aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/unix
diff options
context:
space:
mode:
authorAndreas Schwab <schwab@redhat.com>2010-09-27 22:34:21 -0400
committerUlrich Drepper <drepper@gmail.com>2010-09-27 22:34:21 -0400
commitc21cc9bcb38a87ff638d1099ca871d94a2192b31 (patch)
tree7e7f5bb4024a718f76f668f1f0f49b9f0444cce2 /sysdeps/unix
parent315970f6ca97a589c9220ed5481dbe000137373d (diff)
downloadglibc-c21cc9bcb38a87ff638d1099ca871d94a2192b31.tar
glibc-c21cc9bcb38a87ff638d1099ca871d94a2192b31.tar.gz
glibc-c21cc9bcb38a87ff638d1099ca871d94a2192b31.tar.bz2
glibc-c21cc9bcb38a87ff638d1099ca871d94a2192b31.zip
Properly convert f_fsid in statvfs
Diffstat (limited to 'sysdeps/unix')
-rw-r--r--sysdeps/unix/sysv/linux/internal_statvfs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/internal_statvfs.c b/sysdeps/unix/sysv/linux/internal_statvfs.c
index 0169ae341a..83ffb99c05 100644
--- a/sysdeps/unix/sysv/linux/internal_statvfs.c
+++ b/sysdeps/unix/sysv/linux/internal_statvfs.c
@@ -228,7 +228,8 @@ INTERNAL_STATVFS (const char *name, struct STATVFS *buf,
buf->f_files = fsbuf->f_files;
buf->f_ffree = fsbuf->f_ffree;
if (sizeof (buf->f_fsid) == sizeof (fsbuf->f_fsid))
- buf->f_fsid = (fsbuf->f_fsid.__val[0]
+ buf->f_fsid = ((fsbuf->f_fsid.__val[0]
+ & ((1UL << (8 * sizeof (fsbuf->f_fsid.__val[0]))) - 1))
| ((unsigned long int) fsbuf->f_fsid.__val[1]
<< (8 * (sizeof (buf->f_fsid)
- sizeof (fsbuf->f_fsid.__val[0])))));