From afe82def33be6ae4aafb08d91a221d3395648a7b Mon Sep 17 00:00:00 2001 From: Andy McFadden Date: Tue, 8 Oct 2002 23:57:41 +0000 Subject: [PATCH] Changed FakeZeroExtract from a "mimic SHK" feature to a generally supported bug workaround. --- nufxlib-0/Record.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/nufxlib-0/Record.c b/nufxlib-0/Record.c index a04fc00..1733596 100644 --- a/nufxlib-0/Record.c +++ b/nufxlib-0/Record.c @@ -1575,8 +1575,14 @@ Nu_StreamExtract(NuArchive* pArchive) * If we're trying to be compatible with ShrinkIt, and the record * had nothing in it but comments and filenames, then we need to * create a zero-byte data file. + * + * [ I'm going to make this a non-Mimic feature, so I can turn + * MimicSHK off and still extract zero-byte files from GSHK + * archives. We should perhaps consider a separate "bug + * workaround" flag to control this. Note there's similar + * code in Nu_ExtractRecordByPtr, below. ] */ - if (pArchive->valMimicSHK && !hasInterestingThread) { + if (/*pArchive->valMimicSHK &&*/ !hasInterestingThread) { err = Nu_FakeZeroExtract(pArchive, &tmpRecord); BailError(err); } @@ -1701,7 +1707,7 @@ Nu_ExtractRecordByPtr(NuArchive* pArchive, NuRecord* pRecord) * had nothing in it but comments and filenames, then we need to * create a zero-byte data file. */ - if (pArchive->valMimicSHK && !hasInterestingThread) { + if (/*pArchive->valMimicSHK &&*/ !hasInterestingThread) { err = Nu_FakeZeroExtract(pArchive, pRecord); BailError(err); }