From cfd08b5d6cf8c344e497a3c037890a2e0124dbd0 Mon Sep 17 00:00:00 2001 From: Kp Date: Sat, 25 Jul 2015 23:10:48 +0000 Subject: [PATCH] Suppress physfsx read/write macros in physfsrwops.cpp --- d2x-rebirth/misc/physfsrwops.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/d2x-rebirth/misc/physfsrwops.cpp b/d2x-rebirth/misc/physfsrwops.cpp index 13bafa882..209631f39 100644 --- a/d2x-rebirth/misc/physfsrwops.cpp +++ b/d2x-rebirth/misc/physfsrwops.cpp @@ -106,7 +106,7 @@ static int physfsrwops_seek(SDL_RWops *rw, int offset, int whence) static int physfsrwops_read(SDL_RWops *rw, void *ptr, int size, int maxnum) { PHYSFS_file *handle = (PHYSFS_file *) rw->hidden.unknown.data1; - PHYSFS_sint64 rc = PHYSFS_read(handle, ptr, size, maxnum); + PHYSFS_sint64 rc = (PHYSFS_read)(handle, ptr, size, maxnum); if (rc != maxnum) { if (!PHYSFS_eof(handle)) /* not EOF? Must be an error. */ @@ -120,7 +120,7 @@ static int physfsrwops_read(SDL_RWops *rw, void *ptr, int size, int maxnum) static int physfsrwops_write(SDL_RWops *rw, const void *ptr, int size, int num) { PHYSFS_file *handle = (PHYSFS_file *) rw->hidden.unknown.data1; - PHYSFS_sint64 rc = PHYSFS_write(handle, ptr, size, num); + PHYSFS_sint64 rc = (PHYSFS_write)(handle, reinterpret_cast(ptr), size, num); if (rc != num) SDL_SetError("PhysicsFS error: %s", PHYSFS_getLastError());