Skip to content

Commit 8c7bd75

Browse files
committed
xrCore/FS (IReader): Fixed close() compilation.
There was a deletion call xr_delete(this) and xr_delete() tries to set passed argument (this) to NULL, or accept a pointer to const, which is not the case either. Used the same thing, as in other close() methods: introduced variable self, which is passed to xr_delete().
1 parent 1ae74ad commit 8c7bd75

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/xrCore/FS.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -362,7 +362,8 @@ IReader* IReader::open_chunk(u32 ID)
362362
};
363363
void IReader::close()
364364
{
365-
xr_delete((IReader*)this);
365+
IReader *self = this;
366+
xr_delete(self);
366367
}
367368

368369
#include "FS_impl.h"

0 commit comments

Comments
 (0)