Lines Matching refs:entry_name
548 static bool UnzipToMemory(ZipArchiveHandle zip, const std::string& entry_name, in UnzipToMemory() argument
551 if (FindEntry(zip, entry_name, &zip_entry) != 0) { in UnzipToMemory()
552 fprintf(stderr, "archive does not contain '%s'\n", entry_name.c_str()); in UnzipToMemory()
557 die("entry '%s' is too large: %" PRIu64, entry_name.c_str(), zip_entry.uncompressed_length); in UnzipToMemory()
561 fprintf(stderr, "extracting %s (%zu MB) to RAM...\n", entry_name.c_str(), in UnzipToMemory()
566 if (error != 0) die("failed to extract '%s': %s", entry_name.c_str(), ErrorCodeString(error)); in UnzipToMemory()
661 static unique_fd unzip_to_file(ZipArchiveHandle zip, const char* entry_name) { in unzip_to_file() argument
662 unique_fd fd(make_temporary_fd(entry_name)); in unzip_to_file()
665 if (FindEntry(zip, entry_name, &zip_entry) != 0) { in unzip_to_file()
666 fprintf(stderr, "archive does not contain '%s'\n", entry_name); in unzip_to_file()
671 fprintf(stderr, "extracting %s (%" PRIu64 " MB) to disk...", entry_name, in unzip_to_file()
676 die("\nfailed to extract '%s': %s", entry_name, ErrorCodeString(error)); in unzip_to_file()
680 die("\nlseek on extracted file '%s' failed: %s", entry_name, strerror(errno)); in unzip_to_file()