Skip to content

Commit 9bd721a

Browse files
committed
Revert back to AllocMem
1 parent dddefdb commit 9bd721a

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

include/tabexec.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
#define BPEN_SEP_ID 104
6060
#define PSTACK_ID 105
6161

62-
#define DEFAULT_PATH "System:C,System:Tools"
62+
#define DEFAULT_PATH "SYS:C,SYS:Tools"
6363

6464
#define ESCAPE_C (unsigned char)'\033'
6565
#define PLUS_C (unsigned char)'\012' //ctrl-j

src/tabexec.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -335,8 +335,7 @@ static int init_dawin(void)
335335
return DONE;
336336
}
337337

338-
//vars = (struct Vars *)AllocMem(sizeof(struct Vars), MEMF_CLEAR); //-V2544
339-
vars = (struct Vars *)malloc(sizeof(struct Vars)); //-V2544
338+
vars = (struct Vars *)AllocMem(sizeof(struct Vars), MEMF_CLEAR); //-V2544
340339
if (vars != NULL) {
341340
vars->sgg_Extend.Pens[0] = (unsigned char)drawinfo->dri_Pens[FILLTEXTPEN];
342341
vars->sgg_Extend.Pens[1] = (unsigned char)drawinfo->dri_Pens[FILLPEN];
@@ -774,6 +773,6 @@ static void cleanup(void)
774773
freetext();
775774
CloseWindow(dawin);
776775
FreeSignal((long)deadsignum);
777-
free(vars);
776+
FreeMem(vars, sizeof(struct Vars));
778777
FreeScreenDrawInfo(screen, drawinfo);
779778
}

tabexec.info

12 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)