help-zile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[zile-devel] 2.2.1: LP64 critical fix


From: Christian Weisgerber
Subject: [zile-devel] 2.2.1: LP64 critical fix
Date: Sat, 16 Jul 2005 16:44:48 +0200
User-agent: Mutt/1.4.2.1i

[I'm not subscribed to zile-devel.]

The previous version of zile I had looked at was 2.0.6.  Somewhere
between there and 2.2.1 various variables were changed from int to
size_t.  Here is one allocation that wasn't updated, which causes
zile to segfault on 64-bit architectures.  The same code is also in
term_epocemx.c and should be fixed there as well, I guess.

--- src/term_termcap.c.orig     Sat Jul 16 16:34:20 2005
+++ src/term_termcap.c  Sat Jul 16 16:34:55 2005
@@ -284,8 +284,8 @@ static void init_screen(void)
 
   read_screen_size();
   size = ZILE_COLS * ZILE_LINES;
-  screen.array = zrealloc(screen.array, size * sizeof(int));
-  screen.oarray = zrealloc(screen.oarray, size * sizeof(int));
+  screen.array = zrealloc(screen.array, size * sizeof(size_t));
+  screen.oarray = zrealloc(screen.oarray, size * sizeof(size_t));
   screen.curx = screen.cury = 0;
 }
 
-- 
Christian "naddy" Weisgerber                          address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]