Module Name: src
Committed By: christos
Date: Mon Mar 19 16:20:58 UTC 2012
Modified Files:
src/lib/libc/gen: nlist_ecoff.c
Log Message:
don't do arithmetic on void pointer.
To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/lib/libc/gen/nlist_ecoff.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/lib/libc/gen/nlist_ecoff.c
diff -u src/lib/libc/gen/nlist_ecoff.c:1.19 src/lib/libc/gen/nlist_ecoff.c:1.20
--- src/lib/libc/gen/nlist_ecoff.c:1.19 Sun Mar 18 10:34:28 2012
+++ src/lib/libc/gen/nlist_ecoff.c Mon Mar 19 12:20:58 2012
@@ -1,4 +1,4 @@
-/* $NetBSD: nlist_ecoff.c,v 1.19 2012/03/18 14:34:28 christos Exp $ */
+/* $NetBSD: nlist_ecoff.c,v 1.20 2012/03/19 16:20:58 christos Exp $ */
/*
* Copyright (c) 1996 Christopher G. Demetriou
@@ -36,7 +36,7 @@
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: nlist_ecoff.c,v 1.19 2012/03/18 14:34:28 christos Exp $");
+__RCSID("$NetBSD: nlist_ecoff.c,v 1.20 2012/03/19 16:20:58 christos Exp $");
#endif /* LIBC_SCCS and not lint */
#include "namespace.h"
@@ -157,8 +157,8 @@ __fdnlist_ecoff(fd, list)
if (*nlistname == '_')
nlistname++;
- symtabname =
- &mappedfile[extstroff + esyms[i].es_strindex];
+ symtabname = (void *)((char *)
+ mappedfile + (extstroff + esyms[i].es_strindex));
if (!strcmp(symtabname, nlistname)) {
/*