]> wimlib.net Git - wimlib/blobdiff - src/extract.c
Remove WIMLIB_COMPRESSION_TYPE_INVALID from library
[wimlib] / src / extract.c
index a6b8d9ef057e450227cc76a2822e779be74c56e8..42a52eb54ccf312398e5d85f16b9bfa7a94bda3a 100644 (file)
@@ -67,9 +67,8 @@
 #include <sys/stat.h>
 #include <unistd.h>
 
-#define WIMLIB_EXTRACT_FLAG_MULTI_IMAGE 0x80000000
-#define WIMLIB_EXTRACT_FLAG_FROM_PIPE   0x40000000
-#define WIMLIB_EXTRACT_FLAG_IMAGEMODE   0x20000000
+#define WIMLIB_EXTRACT_FLAG_FROM_PIPE   0x80000000
+#define WIMLIB_EXTRACT_FLAG_IMAGEMODE   0x40000000
 
 /* Keep in sync with wimlib.h  */
 #define WIMLIB_EXTRACT_MASK_PUBLIC                             \
@@ -114,7 +113,6 @@ dentry_is_supported(struct wim_dentry *dentry,
 
 
 #define PWM_ALLOW_WIM_HDR 0x00001
-#define PWM_SILENT_EOF   0x00002
 
 /* Read the header from a stream in a pipable WIM.  */
 static int
@@ -164,8 +162,7 @@ read_pwm_stream_header(WIMStruct *pwm, struct wim_lookup_table_entry *lte,
        return 0;
 
 read_error:
-       if (ret != WIMLIB_ERR_UNEXPECTED_END_OF_FILE || !(flags & PWM_SILENT_EOF))
-               ERROR_WITH_ERRNO("Error reading pipable WIM from pipe");
+       ERROR_WITH_ERRNO("Error reading pipable WIM from pipe");
        return ret;
 }
 
@@ -442,7 +439,7 @@ remove_contained_trees(struct wim_dentry **trees, size_t num_trees)
        for (i = 0; i < num_trees; i++) {
                struct wim_dentry *d = trees[i];
                while (!dentry_is_root(d)) {
-                       d = d->parent;
+                       d = d->d_parent;
                        if (d->tmp_flag)
                                goto tree_contained;
                }
@@ -509,7 +506,7 @@ build_dentry_list(struct list_head *dentry_list, struct wim_dentry **trees,
                        place_after = dentry_list;
                        ancestor = dentry;
                        do {
-                               ancestor = ancestor->parent;
+                               ancestor = ancestor->d_parent;
                                if (will_extract_dentry(ancestor)) {
                                        place_after = &ancestor->d_extraction_list_node;
                                        break;
@@ -518,7 +515,7 @@ build_dentry_list(struct list_head *dentry_list, struct wim_dentry **trees,
 
                        ancestor = dentry;
                        do {
-                               ancestor = ancestor->parent;
+                               ancestor = ancestor->d_parent;
                                if (will_extract_dentry(ancestor))
                                        break;
                                list_add(&ancestor->d_extraction_list_node, place_after);
@@ -1570,8 +1567,6 @@ extract_all_images(WIMStruct *wim, const tchar *target, int extract_flags)
        int image;
        const tchar *image_name;
 
-       extract_flags |= WIMLIB_EXTRACT_FLAG_MULTI_IMAGE;
-
        if (extract_flags & WIMLIB_EXTRACT_FLAG_NTFS) {
                ERROR("Cannot extract multiple images in NTFS extraction mode.");
                return WIMLIB_ERR_INVALID_PARAM;