xfs: bulletfproof xfs_qm_scall_trunc_qfiles()
authorEric Sandeen <sandeen@redhat.com>
Mon, 5 May 2014 07:27:06 +0000 (17:27 +1000)
committerDave Chinner <david@fromorbit.com>
Mon, 5 May 2014 07:27:06 +0000 (17:27 +1000)
commitf58522c5a47a1862c6b3fad97ea9285c5d68199d
tree38014a3199297f7b7ccece36eb8ad18d8072943c
parent9da93f9b7cdf8ab28da6b364cdc1fafc8670b4dc
xfs: bulletfproof xfs_qm_scall_trunc_qfiles()

Coverity noticed that if we sent junk into
xfs_qm_scall_trunc_qfiles(), we could get back an
uninitialized error value.  So sanitize the flags we
will accept, and initialize error anyway for good measure.

(This bug may have been introduced via c61a9e39).

Should resolve Coverity CID 1163872.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Jie Liu <jeff.liu@oracle.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
fs/xfs/xfs_qm_syscalls.c