From 5632bb8892a6f9982088d4b2f058792efcafd647 Mon Sep 17 00:00:00 2001 From: wjrforcyber Date: Sat, 1 Mar 2025 21:03:51 +0800 Subject: [PATCH] Fix(Pointer): Fix the wrong value passed to size Signed-off-by: wjrforcyber --- src/map/scl/sclLiberty.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/map/scl/sclLiberty.c b/src/map/scl/sclLiberty.c index 236e6ef24..2e3838eea 100644 --- a/src/map/scl/sclLiberty.c +++ b/src/map/scl/sclLiberty.c @@ -600,7 +600,7 @@ char * Scl_LibertyFileContents( char * pFileName, long * nContents ) else { FILE * pFile = fopen( pFileName, "rb" ); - pContents = ABC_ALLOC( char, nContents+1 ); + pContents = ABC_ALLOC( char, *nContents+1 ); long RetValue = 0; RetValue = fread( pContents, *nContents, 1, pFile ); fclose( pFile );