diff options
author | Eric Wong <normalperson@yhbt.net> | 2008-09-23 22:37:40 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-09-23 22:37:40 +0200 |
commit | 5cc5c378560acb0629fff40053e948eb071c0885 (patch) | |
tree | c694dcbfc105e1245ce4883184e3dda3977130e6 /src | |
parent | 28d39948d72b8c26b2863a167149c2c2ca232062 (diff) | |
download | mpd-5cc5c378560acb0629fff40053e948eb071c0885.tar.gz mpd-5cc5c378560acb0629fff40053e948eb071c0885.tar.xz mpd-5cc5c378560acb0629fff40053e948eb071c0885.zip |
directory: don't leak file handles if we get a corrupt db
Diffstat (limited to '')
-rw-r--r-- | src/directory.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/directory.c b/src/directory.c index 52f9cb48b..a3efdf15e 100644 --- a/src/directory.c +++ b/src/directory.c @@ -1052,7 +1052,7 @@ int readDirectoryDB(void) } else { ERROR("db info not found in db file\n"); ERROR("you should recreate the db using --create-db\n"); - fseek(fp, 0, SEEK_SET); + while (fclose(fp) && errno == EINTR) ; return -1; } } |