summaryrefslogtreecommitdiff
path: root/scripts/kallsyms.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-10-28 15:13:55 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2010-10-28 15:13:55 -0700
commitc9e2a72ff1acfdffdecb338b3d997f90c507e665 (patch)
tree9be4b7e6a1cb90ffa86148a3937021118a5913c0 /scripts/kallsyms.c
parent9aca0e7c8c3a8f1fa6e3058abc5465b0509f0f8e (diff)
parentd63f6d1b4d3ad0d88685a5f8eb1c3cac01ddd0db (diff)
Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6
* 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild-2.6: initramfs: Fix build break on symbol-prefixed archs initramfs: fix initramfs size calculation initramfs: generalize initramfs_data.xxx.S variants scripts/kallsyms: Enable error messages while hush up unnecessary warnings scripts/setlocalversion: update comment kbuild: Use a single clean rule for kernel and external modules kbuild: Do not run make clean in $(srctree) scripts/mod/modpost.c: fix commentary accordingly to last changes kbuild: Really don't clean bounds.h and asm-offsets.h
Diffstat (limited to 'scripts/kallsyms.c')
-rw-r--r--scripts/kallsyms.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/scripts/kallsyms.c b/scripts/kallsyms.c
index e3902fb39afd..60dd3eb9366e 100644
--- a/scripts/kallsyms.c
+++ b/scripts/kallsyms.c
@@ -107,12 +107,8 @@ static int read_symbol(FILE *in, struct sym_entry *s)
rc = fscanf(in, "%llx %c %499s\n", &s->addr, &stype, str);
if (rc != 3) {
- if (rc != EOF) {
- /* skip line. sym is used as dummy to
- * shut of "warn_unused_result" warning.
- */
- sym = fgets(str, 500, in);
- }
+ if (rc != EOF && fgets(str, 500, in) == NULL)
+ fprintf(stderr, "Read error or end of file.\n");
return -1;
}