git://wimlib.net
/
wimlib
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
54ab9fc
)
wimlib_mount_image(): Delete staging dir on error paths
author
Eric Biggers
<ebiggers3@gmail.com>
Fri, 25 Jan 2013 05:44:50 +0000
(23:44 -0600)
committer
Eric Biggers
<ebiggers3@gmail.com>
Fri, 25 Jan 2013 05:45:51 +0000
(23:45 -0600)
src/mount_image.c
patch
|
blob
|
history
diff --git
a/src/mount_image.c
b/src/mount_image.c
index 28a807d7afdfd7d26537a57a97d99e5203564841..a05a822d10d78d0f2dc92b94076acdba5d7a36b4 100644
(file)
--- a/
src/mount_image.c
+++ b/
src/mount_image.c
@@
-2499,6
+2499,12
@@
WIMLIBAPI int wimlib_mount_image(WIMStruct *wim, int image, const char *dir,
if (ret)
ret = WIMLIB_ERR_FUSE;
+
+ /* Try to delete the staging directory if a deletion wasn't yet
+ * attempted due to an earlier error */
+ if (ctx.staging_dir_name)
+ delete_staging_dir(&ctx);
+
out_free_dir_copy:
FREE(dir_copy);
out_unlock: