kconfig: use xfwrite wrapper function to silence warnings
authorPeter Foley <pefoley2@verizon.net>
Sat, 22 Oct 2011 14:48:49 +0000 (10:48 -0400)
committerChristian Lamparter <chunkeey@googlemail.com>
Sat, 5 May 2012 13:04:55 +0000 (15:04 +0200)
Use the xfwrite wrapper function defined in lkc.h to check the return value of
fwrite and silence these warnings.

  HOSTCC  scripts/kconfig/zconf.tab.o
config/zconf.tab.c: In function 'header_print_comment':
config/confdata.c:551:10: warning: ignoring return value of 'fwrite', declared with attribute warn_unused_result
config/zconf.tab.c: In function 'kconfig_print_comment':
config/confdata.c:467:10: warning: ignoring return value of 'fwrite', declared with attribute warn_unused_result

Signed-off-by: Peter Foley <pefoley2@verizon.net>
Signed-off-by: Michal Marek <mmarek@suse.cz>
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
config/confdata.c

index 54b19b06fb1627b857fcf8d4959ef640dd3e3fcf..834684134eadded264d7d609b0746f52a3b8c403 100644 (file)
@@ -504,7 +504,7 @@ kconfig_print_comment(FILE *fp, const char *value, void *arg)
                fprintf(fp, "#");
                if (l) {
                        fprintf(fp, " ");
-                       fwrite(p, l, 1, fp);
+                       xfwrite(p, l, 1, fp);
                        p += l;
                }
                fprintf(fp, "\n");
@@ -583,7 +583,7 @@ header_print_comment(FILE *fp, const char *value, void *arg)
                fprintf(fp, " *");
                if (l) {
                        fprintf(fp, " ");
-                       fwrite(p, l, 1, fp);
+                       xfwrite(p, l, 1, fp);
                        p += l;
                }
                fprintf(fp, "\n");