From 1c38f82dddac6eaf41d27649bdf50057a1bb543b Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Fri, 15 Jul 2011 15:03:18 +0200 Subject: fixed pointer formatting on systems where sizeof(int) != sizeof(void*) this avoids most of the remaining compiler warnings --- tecmem.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'tecmem.c') diff --git a/tecmem.c b/tecmem.c index 708a946..71b595e 100644 --- a/tecmem.c +++ b/tecmem.c @@ -227,8 +227,8 @@ register int i; mp = (struct memblock *)( addr - sizeof(struct memblock) ); if(mp->type != type){ - printf("\nTEC_RELEASE: TYPE Mismatch: Supplied %d Stored %d addr 0x%x\n", - type,mp->type,(unsigned int)addr); + printf("\nTEC_RELEASE: TYPE Mismatch: Supplied %d Stored %d addr %p\n", + type, mp->type, addr); #ifdef UNIX kill(getpid(),SIGQUIT); #endif @@ -278,9 +278,8 @@ register int i; mp = (struct memblock *)( addr - sizeof(struct memblock) ); if(mp->type != type){ - printf( - "\nTYPE Mismatch: Supplied %d Stored %d addr %x '%s'\n", - type,mp->type,(unsigned int)addr,message); + printf("\nTYPE Mismatch: Supplied %d Stored %d addr %p '%s'\n", + type, mp->type, addr, message); exit(1); }/* End IF */ -- cgit v1.2.3