Skip to content

Commit

Permalink
Merge pull request #475 from zowe/bugfix/iarv64-0x7FFFF000
Browse files Browse the repository at this point in the history
IARV64 results need to be checked for 0x7FFFF000
  • Loading branch information
JoeNemo authored Aug 22, 2024
2 parents 3748d94 + 352528b commit 6d46ea2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Zowe Common C Changelog

## `2.18.1`
- Bugfix: IARV64 results must be checked for 0x7FFFF000 (#474)

## `2.18.0`
- Minor `components.zss.logLevels._zss.httpserver=5` debug messages enhancement (#471)

Expand Down
14 changes: 12 additions & 2 deletions c/alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,12 @@ static char* __ptr64 getmain64(long long sizeInMegabytes, int *returnCode, int *

if (returnCode) *returnCode = macroRetCode;
if (reasonCode) *reasonCode = macroResCode;


// IARV64 returns 0x7FFFF000 when MEMLIMIT is reached
if (data == (void *)0x7FFFF000) {
data = NULL;
}

return data;

}
Expand All @@ -202,7 +207,12 @@ static char* __ptr64 getmain64ByToken(long long sizeInMegabytes, long long token

if (returnCode) *returnCode = macroRetCode;
if (reasonCode) *reasonCode = macroResCode;


// IARV64 returns 0x7FFFF000 when MEMLIMIT is reached
if (data == (void *)0x7FFFF000) {
data = NULL;
}

return data;

}
Expand Down

0 comments on commit 6d46ea2

Please sign in to comment.