OSDN Git Service

util/disk_cache: close fd in the fallback path
authorEric Engestrom <eric.engestrom@intel.com>
Tue, 19 Mar 2019 14:36:30 +0000 (14:36 +0000)
committerEric Engestrom <eric@engestrom.ch>
Thu, 28 Mar 2019 16:41:27 +0000 (16:41 +0000)
commit7fefa4610d96bc65322c73879da83b24487b2c90
treee0ead5010d4b3aef50ab5efd68deaf4cfda07084
parent6596eb2b3080e8858bee3d89041df068333c250a
util/disk_cache: close fd in the fallback path

There are multiple `goto path_fail` with an open fd, but none that go to
`fail:` without going through `path_fail:` first, so let's just move the
`close(fd)` there.

Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/util/disk_cache.c