Fixed stuffextract crash for some maps with compilation under VC80 and newer

This commit is contained in:
bluma4862 2008-04-05 14:47:59 +00:00
parent 5aeccb7a77
commit 24e62993df

View File

@ -515,7 +515,8 @@ void ExtractMaps(void)
printf("\nERROR: Map extraction failed: could not save file %s\n",wdt_out);
return;
}
wdt_fh.write((char*)wdt_bb.contents(),wdt_bb.size());
if (wdt_bb.size())
wdt_fh.write((char*)wdt_bb.contents(),wdt_bb.size());
wdt_fh.close();
printf("Extracted WDT '%s'\n",wdt_name);