mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2026-01-29 17:38:16 +03:00
Contextualize PHYSFS_mountHandle() failure output
If PHYSFS_mountHandle() failed to mount a zip file, we would print PhysFS's error message straight, without any surrounding context. This seems a little weird, and doesn't maximize understanding for readers; I've made it so now the error message is "Could not mount <zip file>: <PhysFS error>".
This commit is contained in:
@@ -87,7 +87,11 @@ void editorclass::loadZips()
|
||||
if (endsWith(directoryList[i], ".zip")) {
|
||||
PHYSFS_File* zip = PHYSFS_openRead(directoryList[i].c_str());
|
||||
if (!PHYSFS_mountHandle(zip, directoryList[i].c_str(), "levels", 1)) {
|
||||
printf("%s\n", PHYSFS_getErrorByCode(PHYSFS_getLastErrorCode()));
|
||||
printf(
|
||||
"Could not mount %s: %s\n",
|
||||
filename_.c_str(),
|
||||
PHYSFS_getErrorByCode(PHYSFS_getLastErrorCode())
|
||||
);
|
||||
} else {
|
||||
needsReload = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user