diff options
author | Theodore Ts'o <tytso@mit.edu> | 2005-07-25 11:36:43 -0500 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2005-07-25 11:36:43 -0500 |
commit | 583d1f83284ddfe126d97e6db0020739a1609b5a (patch) | |
tree | f271a877450d0297a7195ec500575e2f80075cb6 | |
parent | 8c5829fb8e7a59d4bf1ef82f65301658da7b2a3b (diff) | |
download | e2fsprogs-583d1f83284ddfe126d97e6db0020739a1609b5a.tar.gz |
Fix false positives from valgrind: prctl(PR_GET_DUMPABLE)
Pass in zero to the unusued arguments of prctl(PR_GET_DUMPABLE) to
avoid false positives from valgrind.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
-rw-r--r-- | lib/blkid/ChangeLog | 6 | ||||
-rw-r--r-- | lib/blkid/cache.c | 4 | ||||
-rw-r--r-- | lib/ext2fs/ChangeLog | 15 | ||||
-rw-r--r-- | lib/ext2fs/test_io.c | 4 | ||||
-rw-r--r-- | lib/ss/ChangeLog | 6 | ||||
-rw-r--r-- | lib/ss/pager.c | 4 |
6 files changed, 29 insertions, 10 deletions
diff --git a/lib/blkid/ChangeLog b/lib/blkid/ChangeLog index 767f11e1..1bb8cd31 100644 --- a/lib/blkid/ChangeLog +++ b/lib/blkid/ChangeLog @@ -1,3 +1,9 @@ +2005-07-25 Theodore Ts'o <tytso@mit.edu> + + * cache.c (safe_getenv): Pass in zero to the unusued arguments of + prctl(PR_GET_DUMPABLE) to avoid false positives from + valgrind. + 2005-07-09 Andreas Dilger <adilger@clusterfs.com> * getsize.c (blkid_get_dev_size): Use fstat/fstat64 to get size of diff --git a/lib/blkid/cache.c b/lib/blkid/cache.c index b43be606..b47b4880 100644 --- a/lib/blkid/cache.c +++ b/lib/blkid/cache.c @@ -36,11 +36,11 @@ static char *safe_getenv(const char *arg) if ((getuid() != geteuid()) || (getgid() != getegid())) return NULL; #if HAVE_PRCTL - if (prctl(PR_GET_DUMPABLE) == 0) + if (prctl(PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #else #if (defined(linux) && defined(SYS_prctl)) - if (syscall(SYS_prctl, PR_GET_DUMPABLE) == 0) + if (syscall(SYS_prctl, PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #endif #endif diff --git a/lib/ext2fs/ChangeLog b/lib/ext2fs/ChangeLog index b586a6b2..8202608b 100644 --- a/lib/ext2fs/ChangeLog +++ b/lib/ext2fs/ChangeLog @@ -1,11 +1,18 @@ +2005-07-25 Theodore Ts'o <tytso@mit.edu> + + * test_io.c (safe_getenv): Pass in zero to the unusued arguments + of prctl(PR_GET_DUMPABLE) to avoid false positives from + valgrind. + 2005-07-19 Theodore Ts'o <tytso@mit.edu> * mkjournal.c (ext2fs_add_journal_inode): Check for the case where the filesystem is apparently not mounted, but the device - is still busy. This can happy when the luser doesn't - bother to mount /proc and has a bogus /etc/mtab. Add a - safety check to save him from his own stupidity, at least - on 2.6 kernels. (Addresses Debian Bug #319002) + is still busy. This can happen when the luser doesn't + bother to mount /proc and has a bogus /etc/mtab, but still + wants to mount the filesystem before using tune2fs(?!?). + Add a safety check to save him from his own stupidity, at + least on 2.6 kernels. (Addresses Debian Bug #319002) 2005-07-09 Andreas Dilger <adilger@clusterfs.com> diff --git a/lib/ext2fs/test_io.c b/lib/ext2fs/test_io.c index 2d426173..03d63ce1 100644 --- a/lib/ext2fs/test_io.c +++ b/lib/ext2fs/test_io.c @@ -145,11 +145,11 @@ static char *safe_getenv(const char *arg) if ((getuid() != geteuid()) || (getgid() != getegid())) return NULL; #if HAVE_PRCTL - if (prctl(PR_GET_DUMPABLE) == 0) + if (prctl(PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #else #if (defined(linux) && defined(SYS_prctl)) - if (syscall(SYS_prctl, PR_GET_DUMPABLE) == 0) + if (syscall(SYS_prctl, PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #endif #endif diff --git a/lib/ss/ChangeLog b/lib/ss/ChangeLog index 389b35f8..13447b05 100644 --- a/lib/ss/ChangeLog +++ b/lib/ss/ChangeLog @@ -1,3 +1,9 @@ +2005-07-25 Theodore Ts'o <tytso@mit.edu> + + * pager.c (ss_safe_getenv): Pass in zero to the unusued arguments + of prctl(PR_GET_DUMPABLE) to avoid false positives from + valgrind. + 2006-06-30 Theodore Ts'o <tytso@mit.edu> * Release of E2fsprogs 1.38 diff --git a/lib/ss/pager.c b/lib/ss/pager.c index e5327782..a7a2a092 100644 --- a/lib/ss/pager.c +++ b/lib/ss/pager.c @@ -46,11 +46,11 @@ char *ss_safe_getenv(const char *arg) if ((getuid() != geteuid()) || (getgid() != getegid())) return NULL; #if HAVE_PRCTL - if (prctl(PR_GET_DUMPABLE) == 0) + if (prctl(PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #else #if (defined(linux) && defined(SYS_prctl)) - if (syscall(SYS_prctl, PR_GET_DUMPABLE) == 0) + if (syscall(SYS_prctl, PR_GET_DUMPABLE, 0, 0, 0, 0) == 0) return NULL; #endif #endif |