diff options
author | наб <[email protected]> | 2022-01-13 20:07:54 +0100 |
---|---|---|
committer | Tony Hutter <[email protected]> | 2022-02-03 15:28:01 -0800 |
commit | c9c9d634aa6f4aeaf867b534a967f2dc73bfa25a (patch) | |
tree | 06b2c678e0c093e64e286655df1cc297531b2e85 /lib | |
parent | 36a91d6ceff48dee36939aa93e60abbec1665c57 (diff) |
linux: libzfs: mount: fix uninitialised flags
They're later |=d with constants, but never reset
Caught by valgrind while investigating
https://github.com/openzfs/zfs/pull/12928#issuecomment-1007496550
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ahelenia Ziemiańska <[email protected]>
Closes #12954
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libzfs/os/linux/libzfs_mount_os.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libzfs/os/linux/libzfs_mount_os.c b/lib/libzfs/os/linux/libzfs_mount_os.c index 21d640538..b800e069e 100644 --- a/lib/libzfs/os/linux/libzfs_mount_os.c +++ b/lib/libzfs/os/linux/libzfs_mount_os.c @@ -327,7 +327,7 @@ do_mount(zfs_handle_t *zhp, const char *mntpt, char *opts, int flags) if (!libzfs_envvar_is_set("ZFS_MOUNT_HELPER")) { char badopt[MNT_LINE_MAX] = {0}; - unsigned long mntflags = flags, zfsflags; + unsigned long mntflags = flags, zfsflags = 0; char myopts[MNT_LINE_MAX] = {0}; if (zfs_parse_mount_options(opts, &mntflags, |