- tmpfile_blob.file_on_disk = ctx->tmpfile_name;
- ret = 0;
- for (u32 i = 0; i < orig_refcnt; i++) {
-
- /* Note: it usually doesn't matter whether we pass the original
- * blob descriptor to callbacks provided by the extraction
- * backend as opposed to the tmpfile blob descriptor, since they
- * shouldn't actually read data from the blob other than through
- * the read_blob_prefix() call below. But for
- * WIMLIB_EXTRACT_FLAG_WIMBOOT mode on Windows it does matter
- * because it needs access to the original WIM resource
- * descriptor in order to create the external backing reference.
- */
-
- orig_blob->out_refcnt = 1;
- orig_blob->inline_blob_extraction_targets[0] = targets[i];
-
- ret = (*cbs->begin_blob)(orig_blob, cbs->begin_blob_ctx);
- if (ret)
- break;
-
- /* Extra SHA-1 isn't necessary here, but it shouldn't hurt as
- * this case is very rare anyway. */
- ret = extract_blob(&tmpfile_blob, tmpfile_blob.size,
- cbs->consume_chunk,
- cbs->consume_chunk_ctx);