linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] kallsyms prints wrong symbol names
@ 2003-01-09 21:58 Petr Vandrovec
  0 siblings, 0 replies; only message in thread
From: Petr Vandrovec @ 2003-01-09 21:58 UTC (permalink / raw)
  To: torvalds; +Cc: ak, linux-kernel

Hi Linus,

Since stem compression arrived to kallsyms table, we are printing
name of symbol BEFORE one we want to print (and empty string for
first symbol) because of we return buffer with copy of last name
we skipped instead of 'name' variable as we did before. So one more
pass through loop is required.

Without this patch my stack traces were really strange...

				Thanks,
					Petr Vandrovec
					vandrove@vc.cvut.cz



--- linux-2.5.55/kernel/kallsyms.c	2003-01-09 22:47:40.000000000 +0100
+++ linux-2.5.55/kernel/kallsyms.c	2003-01-09 22:38:01.000000000 +0100
@@ -46,7 +46,7 @@
 		}
 
 		/* Grab name */
-		for (i = 0; i < best; i++) { 
+		for (i = 0; i < best + 1; i++) { 
 			unsigned prefix = *name++;
 			strncpy(namebuf + prefix, name, 127 - prefix);
 			name += strlen(name) + 1;

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-01-09 21:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-01-09 21:58 [PATCH] kallsyms prints wrong symbol names Petr Vandrovec

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).