src/physfs_archiver_7z.c
branchstable-3.0
changeset 1690 165d972bc790
parent 1634 5c3248d49cfe
child 1691 c66c9326b05d
--- a/src/physfs_archiver_7z.c	Sun May 17 00:58:55 2020 -0400
+++ b/src/physfs_archiver_7z.c	Sun May 17 01:26:31 2020 -0400
@@ -290,7 +290,7 @@
     io = NULL;
 
     buf = allocator.Malloc(outSizeProcessed);
-    GOTO_IF(rc != SZ_OK, PHYSFS_ERR_OUT_OF_MEMORY, SZIP_openRead_failed);
+    GOTO_IF(buf == NULL, PHYSFS_ERR_OUT_OF_MEMORY, SZIP_openRead_failed);
     memcpy(buf, outBuffer + offset, outSizeProcessed);
 
     alloc->Free(alloc, outBuffer);