]> git.ipfire.org Git - thirdparty/libvirt.git/commit
util: virFileIsSharedFixFUSE: Refactor cleanup
authorPeter Krempa <pkrempa@redhat.com>
Mon, 5 Sep 2022 11:57:18 +0000 (13:57 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Mon, 5 Sep 2022 15:32:13 +0000 (17:32 +0200)
commit51741c40b8e8f55c0fabffb3ea7d3a16d27a36b8
tree0bc1ac3924470712bedeadb5fe115d82fff56ef2
parent6db3cc8bc3e3ddbb226408890af6fd0eeceb7bcc
util: virFileIsSharedFixFUSE: Refactor cleanup

Automatically free memory of 'canonPath' so that the failure of
'setmntent' doesn't have to go to 'cleanup'. This allows us to remove
the cleanup section and the 'ret' variable as the rest of the function
can't fail.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
src/util/virfile.c