diff options
author | Geert Uytterhoeven <[email protected]> | 2016-10-20 15:41:48 +1100 |
---|---|---|
committer | Dave Chinner <[email protected]> | 2016-10-20 15:41:48 +1100 |
commit | 1be7f9be0efa4e90547f50b8188f4e70710a1173 (patch) | |
tree | f08149589bee3be8ee9ea4cc73a09ddf6a4d34c5 /tools/perf/util/scripting-engines/trace-event-python.c | |
parent | 1d55a4bfd080ff4c6c96acfccfb7cdd2615ed6c2 (diff) |
xfs: Fix uninitialized variable in xfs_reflink_reserve_cow_range()
with gcc 4.1.2:
fs/xfs/xfs_reflink.c: In function xfs_reflink_reserve_cow_range:
fs/xfs/xfs_reflink.c:327: warning: error may be used uninitialized in this function
Indeed, if "count" is zero, the function will return an uninitialized
error value.
While "count" is unlikely to be zero, this function is called through
the public iomap API. Hence fix this by preinitializing error to zero.
Fixes: 2a06705cd5954030 ("xfs: create delalloc extents in CoW fork")
Signed-off-by: Geert Uytterhoeven <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Signed-off-by: Dave Chinner <[email protected]>
Diffstat (limited to 'tools/perf/util/scripting-engines/trace-event-python.c')
0 files changed, 0 insertions, 0 deletions