Skip to content
Snippets Groups Projects
Commit 65682870 authored by Oliver Sander's avatar Oliver Sander
Browse files

Minor code simplification

[[Imported from SVN: r8473]]
parent b429afe3
No related branches found
No related tags found
No related merge requests found
......@@ -390,15 +390,10 @@ void *NS_PREFIX GetMemUsingKey (HEAP *theHeap, MEM n, HeapAllocMode mode, INT ke
{
if (theHeap->topStackPtr>0)
{
if (key>theHeap->topStackPtr)
/* key > topStackPtr: Mark/Release calls not balanced
* key < topStackPtr: stack pos already released */
if (key != theHeap->topStackPtr)
{
/* Mark/Release calls not balanced */
ASSERT(FALSE);
return(NULL);
}
if (key<theHeap->topStackPtr)
{
/* stack pos already released */
ASSERT(FALSE);
return(NULL);
}
......@@ -412,15 +407,10 @@ void *NS_PREFIX GetMemUsingKey (HEAP *theHeap, MEM n, HeapAllocMode mode, INT ke
{
if (theHeap->bottomStackPtr>0)
{
if (key>theHeap->bottomStackPtr)
{
/* Mark/Release calls not balanced */
ASSERT(FALSE);
return(NULL);
}
if (key<theHeap->bottomStackPtr)
/* key > bottomStackPtr: Mark/Release calls not balanced
* key < bottomStackPtr: stack pos already released */
if (key != theHeap->bottomStackPtr)
{
/* stack pos already released */
ASSERT(FALSE);
return(NULL);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment