From 125189e25ea084771d6b812c04b9394a1aa20f7e Mon Sep 17 00:00:00 2001 From: Yuichi Nishiwaki Date: Sat, 9 Nov 2013 14:11:54 +0900 Subject: [PATCH] fix a bug in initial ciend setting --- src/state.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/state.c b/src/state.c index 852d3083..2717b0f8 100644 --- a/src/state.c +++ b/src/state.c @@ -26,7 +26,7 @@ pic_open(int argc, char *argv[], char **envp) /* callinfo */ pic->cibase = pic->ci = (pic_callinfo *)malloc(sizeof(pic_callinfo) * PIC_STACK_SIZE); - pic->ciend = pic->ciend + PIC_STACK_SIZE; + pic->ciend = pic->cibase + PIC_STACK_SIZE; /* memory heap */ pic->heap = (struct heap_page *)malloc(sizeof(struct heap_page));