-/* Retrieve the full uncompressed data of the specified WIM resource. A buffer
- * large enough hold the data is allocated and returned in @buf_ret. */
-static int
-wim_resource_spec_to_data(struct wim_resource_spec *rspec, void **buf_ret)
-{
- int ret;
- struct wim_lookup_table_entry *lte;
-
- lte = new_lookup_table_entry();
- if (lte == NULL)
- return WIMLIB_ERR_NOMEM;
-
- lte_bind_wim_resource_spec(lte, rspec);
- lte->flags = rspec->flags;
- lte->size = rspec->uncompressed_size;
- lte->offset_in_res = 0;
-
- ret = read_full_stream_into_alloc_buf(lte, buf_ret);
-
- lte_unbind_wim_resource_spec(lte);
- free_lookup_table_entry(lte);
- return ret;
-}
-