From 1586b3b5c4acdfc9f1b1de31f90de91644182fcd Mon Sep 17 00:00:00 2001 From: matsutsuka Date: Fri, 11 Dec 2009 14:59:45 +0000 Subject: [PATCH] fixed minor bug of mt-test due to sdcc --- platform/pc-6001/apps/multithread/mt-test.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/platform/pc-6001/apps/multithread/mt-test.c b/platform/pc-6001/apps/multithread/mt-test.c index 547ba1553..441445e5f 100644 --- a/platform/pc-6001/apps/multithread/mt-test.c +++ b/platform/pc-6001/apps/multithread/mt-test.c @@ -30,7 +30,7 @@ * * Author: Oliver Schmidt * - * $Id: mt-test.c,v 1.2 2007/09/11 12:55:57 matsutsuka Exp $ + * $Id: mt-test.c,v 1.3 2009/12/11 14:59:45 matsutsuka Exp $ */ /** @@ -63,14 +63,14 @@ static char buf[20]; void println(char *str1) { - static unsigned int i; + unsigned int i; for(i = 1; i < WIN_YSIZE; i++) { - memcpy(log + (i - 1) * WIN_XSIZE, log + i * WIN_XSIZE, WIN_XSIZE); + memcpy(&log[(i - 1) * WIN_XSIZE], &log[i * WIN_XSIZE], WIN_XSIZE); } - memset(log + (WIN_YSIZE - 1) * WIN_XSIZE, 0, WIN_XSIZE); + memset(&log[(WIN_YSIZE - 1) * WIN_XSIZE], 0, WIN_XSIZE); - strncpy(log + (WIN_YSIZE - 1) * WIN_XSIZE, str1, WIN_XSIZE); + strncpy(&log[(WIN_YSIZE - 1) * WIN_XSIZE], str1, WIN_XSIZE); CTK_WIDGET_REDRAW(&loglabel); }