Message ID | 1489756546-27142-4-git-send-email-kwolf@redhat.com |
---|---|
State | New |
Headers | show |
diff --git a/block/file-posix.c b/block/file-posix.c index ac6bd9f..53febd3 100644 --- a/block/file-posix.c +++ b/block/file-posix.c @@ -703,6 +703,9 @@ static int hdev_get_max_segments(const struct stat *st) } out: + if (fd != -1) { + close(fd); + } g_free(sysfspath); return ret; #else