On 02/13/2018 07:03 AM, Max Reitz wrote:
glfs_close() is a classical clean-up operation, as can be seen by the
fact that it is executed even if the truncation before it failed.
Also, moving it to clean-up makes it more clear that if it fails, we do
not want it to overwrite the current ret value if that signifies an
error already.

Signed-off-by: Max Reitz <mre...@redhat.com>
---
  block/gluster.c | 10 ++++++----
  1 file changed, 6 insertions(+), 4 deletions(-)


Reviewed-by: Eric Blake <ebl...@redhat.com>


--
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Reply via email to