From: sparky4 Date: Fri, 23 Sep 2016 18:36:19 +0000 (-0500) Subject: added debug variable fix small bug wwww X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=4fc79da332055271a41b9a9735b922ab4f3c07f2;p=16.git added debug variable fix small bug wwww --- diff --git a/DEBUG.16W b/DEBUG.16W index c174d6ff..d8f8cf89 100755 --- a/DEBUG.16W +++ b/DEBUG.16W @@ -1,12 +1,12 @@ -Seg:0 Size:8574 Owner:0x40fe +Seg:0 Size:8575 Owner:0x0 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++0 -Seg:217e Size:256 Owner:0x5438 +Seg:217f Size:256 Owner:0x5438 ++++ -Seg:227e Size:273 Owner:0x9490 +Seg:227f Size:273 Owner:0x9490 ++++ -Seg:27f1 Size:44 Owner:0x0 +Seg:27f2 Size:44 Owner:0x0 ++0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 -Seg:b81d Size:10211 Owner:0x0 +Seg:b81e Size:10210 Owner:0x0 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Seg:e000 Size:8191 Owner:0x0 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ \ No newline at end of file diff --git a/HEAP.16W b/HEAP.16W index 38e4b0b6..ac2b7f9d 100755 --- a/HEAP.16W +++ b/HEAP.16W @@ -1,35 +1,35 @@ == default == - USED block at 28130016 of size 66 - USED block at 28130058 of size 66 - FREE block at 2813009a of size 18 - USED block at 281300ac of size 136 - USED block at 28130134 of size 20 - FREE block at 28130148 of size 7860 + USED block at 28140016 of size 66 + USED block at 28140058 of size 66 + FREE block at 2814009a of size 18 + USED block at 281400ac of size 136 + USED block at 28140134 of size 20 + FREE block at 28140148 of size 7860 OK - end of heap == near == - USED block at 181294c6 of size 12 - USED block at 181294d2 of size 332 - USED block at 1812961e of size 52 - USED block at 18129652 of size 20 - USED block at 18129666 of size 20 - USED block at 1812967a of size 20 - USED block at 1812968e of size 20 - USED block at 181296a2 of size 20 - USED block at 181296b6 of size 26950 + USED block at 181394c6 of size 12 + USED block at 181394d2 of size 332 + USED block at 1813961e of size 52 + USED block at 18139652 of size 20 + USED block at 18139666 of size 20 + USED block at 1813967a of size 20 + USED block at 1813968e of size 20 + USED block at 181396a2 of size 20 + USED block at 181396b6 of size 26950 OK - end of heap == far == - USED block at 28130016 of size 66 - USED block at 28130058 of size 66 - USED block at 2813009a of size 18 - USED block at 281300ac of size 136 - USED block at 28130134 of size 20 - USED block at 28130148 of size 7860 + USED block at 28140016 of size 66 + USED block at 28140058 of size 66 + USED block at 2814009a of size 18 + USED block at 281400ac of size 136 + USED block at 28140134 of size 20 + USED block at 28140148 of size 7860 OK - end of heap Memory Type Total Used Free diff --git a/MMDUMP.16W b/MMDUMP.16W index f71e9027..8420fa4c 100755 Binary files a/MMDUMP.16W and b/MMDUMP.16W differ diff --git a/src/lib/16_mm.c b/src/lib/16_mm.c index 7fce3710..db338fa1 100755 --- a/src/lib/16_mm.c +++ b/src/lib/16_mm.c @@ -47,7 +47,6 @@ Open Watcom port by sparky4 */ #include "src/lib/16_mm.h" -#include "src/lib/16_pm.h" #include "src/lib/16_ca.h" #pragma hdrstop @@ -837,8 +836,7 @@ void MM_Startup(global_game_variables_t *gvar) gvar->mmi.mainmem = gvar->mmi.nearheap + gvar->mmi.farheap; - if(pmdebug>0) - { + if(!pmdebug) { // // detect EMS and allocate up to 64K at page frame // @@ -937,8 +935,10 @@ void MM_Shutdown(global_game_variables_t *gvar) #ifdef __BORLANDC__ free(gvar->mm.nearheap);// printf(" near freed\n"); #endif + if(!pmdebug) { if(MML_CheckForEMS()){ MML_ShutdownEMS(gvar); }//printf(" EMS freed\n"); } if(MML_CheckForXMS(gvar)){ MML_ShutdownXMS(gvar); }//printf(" XMS freed\n"); } + } } //========================================================================== diff --git a/src/lib/16_mm.h b/src/lib/16_mm.h index 1a448a2a..b04c56ab 100755 --- a/src/lib/16_mm.h +++ b/src/lib/16_mm.h @@ -27,6 +27,7 @@ #include "src/lib/16_hc.h" #include "src/lib/16_lib.h" //++++mh #include "src/lib/16_in.h" +extern boolean pmdebug; #ifdef __DEBUG__ // 1 == Debug/Dev ; 0 == Production/final