- use TArray and FString in resource file management.
This commit is contained in:
parent
4d06c17a44
commit
191f2d9d76
13 changed files with 55 additions and 73 deletions
|
|
@ -181,7 +181,7 @@ bool FZipFile::Open(bool quiet)
|
|||
|
||||
if (centraldir == 0)
|
||||
{
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: ZIP file corrupt!\n", Filename);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: ZIP file corrupt!\n", FileName.GetChars());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -193,7 +193,7 @@ bool FZipFile::Open(bool quiet)
|
|||
if (info.NumEntries != info.NumEntriesOnAllDisks ||
|
||||
info.FirstDisk != 0 || info.DiskNumber != 0)
|
||||
{
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Multipart Zip files are not supported.\n", Filename);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Multipart Zip files are not supported.\n", FileName.GetChars());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -229,7 +229,7 @@ bool FZipFile::Open(bool quiet)
|
|||
if (dirptr > ((char*)directory) + dirsize) // This directory entry goes beyond the end of the file.
|
||||
{
|
||||
free(directory);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Central directory corrupted.", Filename);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Central directory corrupted.", FileName.GetChars());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -300,7 +300,7 @@ bool FZipFile::Open(bool quiet)
|
|||
if (dirptr > ((char*)directory) + dirsize) // This directory entry goes beyond the end of the file.
|
||||
{
|
||||
free(directory);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Central directory corrupted.", Filename);
|
||||
if (!quiet) Printf(TEXTCOLOR_RED "\n%s: Central directory corrupted.", FileName.GetChars());
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -320,7 +320,7 @@ bool FZipFile::Open(bool quiet)
|
|||
zip_fh->Method != METHOD_IMPLODE &&
|
||||
zip_fh->Method != METHOD_SHRINK)
|
||||
{
|
||||
if (!quiet) Printf(TEXTCOLOR_YELLOW "\n%s: '%s' uses an unsupported compression algorithm (#%d).\n", Filename, name.GetChars(), zip_fh->Method);
|
||||
if (!quiet) Printf(TEXTCOLOR_YELLOW "\n%s: '%s' uses an unsupported compression algorithm (#%d).\n", FileName.GetChars(), name.GetChars(), zip_fh->Method);
|
||||
skipped++;
|
||||
continue;
|
||||
}
|
||||
|
|
@ -328,7 +328,7 @@ bool FZipFile::Open(bool quiet)
|
|||
zip_fh->Flags = LittleShort(zip_fh->Flags);
|
||||
if (zip_fh->Flags & ZF_ENCRYPTED)
|
||||
{
|
||||
if (!quiet) Printf(TEXTCOLOR_YELLOW "\n%s: '%s' is encrypted. Encryption is not supported.\n", Filename, name.GetChars());
|
||||
if (!quiet) Printf(TEXTCOLOR_YELLOW "\n%s: '%s' is encrypted. Encryption is not supported.\n", FileName.GetChars(), name.GetChars());
|
||||
skipped++;
|
||||
continue;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue