WIMStruct: Rename 'deletion_occurred' to 'image_deletion_occurred'
authorEric Biggers <ebiggers3@gmail.com>
Sat, 13 Dec 2014 19:20:19 +0000 (13:20 -0600)
committerEric Biggers <ebiggers3@gmail.com>
Sat, 13 Dec 2014 19:20:19 +0000 (13:20 -0600)
include/wimlib/wim.h
src/delete_image.c
src/write.c

index 50db70d..412a9f7 100644 (file)
@@ -57,7 +57,7 @@ struct WIMStruct {
        int current_image;
 
        /* Have any images been deleted? */
-       u8 deletion_occurred : 1;
+       u8 image_deletion_occurred : 1;
 
        /* Has the underlying WIM file been locked for appending?  */
        u8 locked_for_append : 1;
index 7e33ea3..533d62c 100644 (file)
@@ -78,7 +78,7 @@ wimlib_delete_image(WIMStruct *wim, int image)
                /* Remove the image from the XML information. */
                xml_delete_image(&wim->wim_info, image);
 
-               wim->deletion_occurred = 1;
+               wim->image_deletion_occurred = 1;
        }
        return 0;
 }
index d8ce2dc..1de3e7a 100644 (file)
@@ -3248,7 +3248,7 @@ overwrite_wim_inplace(WIMStruct *wim, int write_flags, unsigned num_threads)
         * allow any file and metadata resources to appear without returning
         * WIMLIB_ERR_RESOURCE_ORDER (due to the fact that we would otherwise
         * overwrite these resources). */
-       if (!wim->deletion_occurred && !any_images_modified(wim)) {
+       if (!wim->image_deletion_occurred && !any_images_modified(wim)) {
                /* If no images have been modified and no images have been
                 * deleted, a new lookup table does not need to be written.  We
                 * shall write the new XML data and optional integrity table
@@ -3405,8 +3405,9 @@ can_overwrite_wim_inplace(const WIMStruct *wim, int write_flags)
        if (write_flags & WIMLIB_WRITE_FLAG_REBUILD)
                return false;
 
-       /* Deletions cause full rebuild by default.  */
-       if (wim->deletion_occurred && !(write_flags & WIMLIB_WRITE_FLAG_SOFT_DELETE))
+       /* Image deletions cause full rebuild by default.  */
+       if (wim->image_deletion_occurred &&
+           !(write_flags & WIMLIB_WRITE_FLAG_SOFT_DELETE))
                return false;
 
        /* Pipable WIMs cannot be updated in place, nor can a non-pipable WIM be