summaryrefslogtreecommitdiff
path: root/src/utils/physfsrwops.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/utils/physfsrwops.cpp')
-rw-r--r--src/utils/physfsrwops.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/utils/physfsrwops.cpp b/src/utils/physfsrwops.cpp
index 022e8160f..aa5caf7c7 100644
--- a/src/utils/physfsrwops.cpp
+++ b/src/utils/physfsrwops.cpp
@@ -27,6 +27,7 @@
#include "logger.h"
#include "utils/fuzzer.h"
+#include "utils/physfscheckutils.h"
#include <stdio.h>
@@ -161,6 +162,9 @@ static int physfsrwops_close(SDL_RWops *const rw)
logger->log("closing already closed RWops");
openedRWops --;
#endif
+#ifdef DEBUG_PHYSFS
+ FakePhysFSClose(rw);
+#endif
return 0;
} /* physfsrwops_close */
@@ -256,10 +260,12 @@ SDL_RWops *PHYSFSRWOPS_openAppend(const char *const fname)
return create_rwops(PhysFs::openAppend(fname));
} /* PHYSFSRWOPS_openAppend */
+#ifdef DUMP_LEAKED_RESOURCES
void reportRWops()
{
if (openedRWops)
logger->log("leaking RWops: %d", openedRWops);
}
+#endif
/* end of physfsrwops.c ... */