diff options
Diffstat (limited to 'ext/zip/lib/zip_open.c')
-rw-r--r-- | ext/zip/lib/zip_open.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/ext/zip/lib/zip_open.c b/ext/zip/lib/zip_open.c index 4b219556c8..e3840197dd 100644 --- a/ext/zip/lib/zip_open.c +++ b/ext/zip/lib/zip_open.c @@ -69,15 +69,16 @@ zip_open(const char *fn, int flags, int *zep) if (flags & ZIP_OVERWRITE) { return _zip_allocate_new(fn, zep); } - + switch (_zip_file_exists(fn, flags, zep)) { case -1: if (!(flags & ZIP_OVERWRITE)) { - return NULL; + return NULL; } - + case 0: return _zip_allocate_new(fn, zep); + default: break; } |