Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

http://code.google.com/p/libarchive/issues/detail?id=325

Close the file handle on error.
  • Loading branch information...
commit 4b5f6510f262ce30daf3d3ce3f1e36d3dd5a8159 1 parent 2bc28c7
@kientzle kientzle authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 cpio/cpio.c
View
4 cpio/cpio.c
@@ -1235,8 +1235,10 @@ cpio_rename(const char *name)
if (t == NULL)
return (name);
to = fopen("CONOUT$", "w");
- if (to == NULL)
+ if (to == NULL) {
+ fclose(t);
return (name);
+ }
fprintf(to, "%s (Enter/./(new name))? ", name);
fclose(to);
#else
Please sign in to comment.
Something went wrong with that request. Please try again.