btrfs-progs: qgroup: Fix a bug that fails to skip rescan running case
authorQu Wenruo <quwenruo@cn.fujitsu.com>
Thu, 16 Jun 2016 01:15:51 +0000 (09:15 +0800)
committerDavid Sterba <dsterba@suse.com>
Fri, 17 Jun 2016 15:05:22 +0000 (17:05 +0200)
commitdf05c7ed455f519e6e15e46196392e4757257305
treebf1f4b95419f91fa8be780d79851c473a94aceb1
parentb8288277fbb0a46fbc607fd3c5090c03e9e22966
btrfs-progs: qgroup: Fix a bug that fails to skip rescan running case

Commit 6bdf962fe35a8648d(btrfs-progs: Read qgroup status for qgroup
verify) will read qgroup status, and then use it to skip qgroup
reporting.

However since the rescan_running/inconsistent flags are only 1 bit long,
while qgroup flags & BTRFS_QGROUP_FLAGS returns value longer than 1bit,
it doesn't work.

Fix it by doing double negation on (flags & BTRFS_QGROUP_FLAGS) to
convert it to either 1 or 0.

Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
qgroup-verify.c