Re: [PATCH 2/3] Btrfs-progs: add missing error handling in find_mount_root()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 14 Jan 2019 13:31:34 +0000, fdmanana@xxxxxxxxxx wrote:

> From: Filipe Manana <fdmanana@xxxxxxxx>
> 
> The strdup() function can fail, in which case it returns NULL and sets
> errno [1]. Therefore add the missing error check after calling strdup()
> at find_mount_root().
> 
> [1] - http://man7.org/linux/man-pages/man3/strdup.3p.html
> 
> Signed-off-by: Filipe Manana <fdmanana@xxxxxxxx>
> ---
>  utils.c | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)

Looks good:
Reviewed-by: David Disseldorp <ddiss@xxxxxxx>



[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux