- Added textual descriptions of the zlib errors.
SVN r3689 (trunk)
This commit is contained in:
parent
c197d0687c
commit
08272a29ad
6 changed files with 39 additions and 5 deletions
|
|
@ -780,3 +780,33 @@ CCMD (screenshot)
|
|||
else
|
||||
G_ScreenShot (argv[1]);
|
||||
}
|
||||
|
||||
//
|
||||
// M_ZlibError
|
||||
//
|
||||
FString M_ZLibError(int zerr)
|
||||
{
|
||||
if (zerr >= 0)
|
||||
{
|
||||
return "OK";
|
||||
}
|
||||
else if (zerr < -6)
|
||||
{
|
||||
FString out;
|
||||
out.Format("%d", zerr);
|
||||
return out;
|
||||
}
|
||||
else
|
||||
{
|
||||
static const char *errs[6] =
|
||||
{
|
||||
"Errno",
|
||||
"Stream Error",
|
||||
"Data Error",
|
||||
"Memory Error",
|
||||
"Buffer Error",
|
||||
"Version Error"
|
||||
};
|
||||
return errs[-zerr - 1];
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue