diff options
author | Qu Wenruo <quwenruo@cn.fujitsu.com> | 2016-10-24 10:43:35 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-12-14 15:06:34 +0100 |
commit | a2883ea16d15ce02c3279f835736e5072dd6e709 (patch) | |
tree | 01fe98186fb1455c838a6a7d0a5004ccd5d85cd1 /send-stream.c | |
parent | 45f782abf3694d4cf2b61adeccf0c8c8974fc23f (diff) |
btrfs-progs: check: fix NULL pointer dereference for possible memory allocation failure
We didn't check 'path' allocated in check_root_ref(), which can cause
NULL pointer dereference if the memory allocation failed.
Fix it by using stack memory, since the function should return error
bitmap not minus error code, we don't want memory allocation to be an
exception.
Resolves-Coverity-CID: 1372510
Signed-off-by: Qu Wenruo <quwenruo@cn.fujitsu.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'send-stream.c')
0 files changed, 0 insertions, 0 deletions