X-Git-Url: https://wimlib.net/git/?a=blobdiff_plain;f=src%2Fresource.c;h=8c88129626795b3a3a2c0e76f17c6a66b56cfd1a;hb=ca8727cf22a445adc20eb1f8b7a12b8eededc32d;hp=1b53ee40342cf6f5258b4b9bd0b508d4f8fc4500;hpb=2af95e7dc313e9abaf571034c3e86f32503bf232;p=wimlib diff --git a/src/resource.c b/src/resource.c index 1b53ee40..8c881296 100644 --- a/src/resource.c +++ b/src/resource.c @@ -630,6 +630,7 @@ read_wim_resource_prefix(const struct wim_lookup_table_entry *lte, } +#ifndef __WIN32__ static int read_file_on_disk_prefix(const struct wim_lookup_table_entry *lte, u64 size, @@ -676,6 +677,7 @@ out_close: close(fd); return ret; } +#endif /* !__WIN32__ */ static int read_buffer_prefix(const struct wim_lookup_table_entry *lte, @@ -732,7 +734,9 @@ read_resource_prefix(const struct wim_lookup_table_entry *lte, { static const read_resource_prefix_handler_t handlers[] = { [RESOURCE_IN_WIM] = read_wim_resource_prefix, + #ifndef __WIN32__ [RESOURCE_IN_FILE_ON_DISK] = read_file_on_disk_prefix, + #endif [RESOURCE_IN_ATTACHED_BUFFER] = read_buffer_prefix, #ifdef WITH_FUSE [RESOURCE_IN_STAGING_FILE] = read_file_on_disk_prefix, @@ -808,8 +812,8 @@ extract_wim_resource(const struct wim_lookup_table_entry *lte, print_lookup_table_entry(lte, stderr); if (lte->resource_location == RESOURCE_IN_WIM) ERROR("The WIM file appears to be corrupt!"); - ret = WIMLIB_ERR_INVALID_RESOURCE_HASH; #endif + ret = WIMLIB_ERR_INVALID_RESOURCE_HASH; } } } else {