Commit 02538d82 authored by Linus Torvalds's avatar Linus Torvalds

Fix kallsyms symbol lookup code. Let's do this trivial one-character

version before looking at more complicated changes.
parent d8833d34
...@@ -46,7 +46,7 @@ const char *kallsyms_lookup(unsigned long addr, ...@@ -46,7 +46,7 @@ const char *kallsyms_lookup(unsigned long addr,
} }
/* Grab name */ /* Grab name */
for (i = 0; i < best; i++) { for (i = 0; i <= best; i++) {
unsigned prefix = *name++; unsigned prefix = *name++;
strncpy(namebuf + prefix, name, 127 - prefix); strncpy(namebuf + prefix, name, 127 - prefix);
name += strlen(name) + 1; name += strlen(name) + 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment