From patchwork Thu Aug 12 17:21:22 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?J=CE=B5an_Sacren?= X-Patchwork-Id: 119304 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o7CHLIcq030884 for ; Thu, 12 Aug 2010 17:21:18 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754877Ab0HLRVS (ORCPT ); Thu, 12 Aug 2010 13:21:18 -0400 Received: from mail-pw0-f46.google.com ([209.85.160.46]:52011 "EHLO mail-pw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752977Ab0HLRVR (ORCPT ); Thu, 12 Aug 2010 13:21:17 -0400 Received: by pwi4 with SMTP id 4so217828pwi.19 for ; Thu, 12 Aug 2010 10:21:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:mime-version:content-type:content-disposition; bh=65X+NgQj9spU0Sy5906P83bVR/P7kHLeCl6nU3iczqo=; b=ZmcLG1y3PIU126RGTLQgQcseIw308GFw4k8o6AUbxeeDX35sUSNgtV9gb3lFklaHvN udgXpvDedAHiV4SRZzMcfzIipqUjDZOocDOeiNVshCuxTwttm1WULCRITZtMxeQi1aQp CQ9Fcc+/QVU4hvzAMGyH+yZzfX1cELDlKcS8k= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:mime-version:content-type :content-disposition; b=E9Bvx4i1/+h5CqZuRDSeHNEVyNbkBRQPavNJUg/3Jpyb9uL74WYUSBtrnMhKDYOqLc RYZGTxG+0FC10p9dvXI9TSyPR1j90/Afp5flVu8NnpD92xBijxNZDH1qMynay/DnGQMP Ux+hOB+CvzisqXMELpp50X8EmaJUoRed0ZSJg= Received: by 10.142.194.15 with SMTP id r15mr338050wff.31.1281633677112; Thu, 12 Aug 2010 10:21:17 -0700 (PDT) Received: from localhost ([65.181.55.156]) by mx.google.com with ESMTPS id q27sm1815129wfc.6.2010.08.12.10.21.14 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 12 Aug 2010 10:21:15 -0700 (PDT) Date: Thu, 12 Aug 2010 11:21:22 -0600 From: Jean Sacren To: Michal Marek Cc: Jiri Kosina , Roman Zippel , linux-kbuild@vger.kernel.org Subject: [PATCH 1/1] kconfig: fix warning: ignoring return value, declared with attribute warn_unused_result Message-ID: <20100812172122.GA21339@mail.gmail.com> MIME-Version: 1.0 Content-Disposition: inline Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Thu, 12 Aug 2010 17:21:18 +0000 (UTC) diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index 9960d1c..beaa533 100644 --- a/scripts/kconfig/conf.c +++ b/scripts/kconfig/conf.c @@ -77,6 +77,7 @@ static void check_stdin(void) static int conf_askvalue(struct symbol *sym, const char *def) { + char *dummy; enum symbol_type type = sym_get_type(sym); if (!sym_has_value(sym)) @@ -102,7 +103,7 @@ static int conf_askvalue(struct symbol *sym, const char *def) check_stdin(); case ask_all: fflush(stdout); - fgets(line, 128, stdin); + dummy = fgets(line, 128, stdin); return 1; default: break; @@ -230,6 +231,7 @@ static int conf_choice(struct menu *menu) struct menu *child; int type; bool is_new; + char *dummy; sym = menu->sym; type = sym_get_type(sym); @@ -304,7 +306,7 @@ static int conf_choice(struct menu *menu) check_stdin(); case ask_all: fflush(stdout); - fgets(line, 128, stdin); + dummy = fgets(line, 128, stdin); strip(line); if (line[0] == '?') { print_help(menu); diff --git a/scripts/kconfig/confdata.c b/scripts/kconfig/confdata.c index c4dec80..52c6c3d 100644 --- a/scripts/kconfig/confdata.c +++ b/scripts/kconfig/confdata.c @@ -408,6 +408,7 @@ int conf_write(const char *name) time_t now; int use_timestamp = 1; char *env; + size_t dummy; dirname[0] = 0; if (name && name[0]) { @@ -505,7 +506,7 @@ int conf_write(const char *name) while (1) { l = strcspn(str, "\"\\"); if (l) { - fwrite(str, l, 1, out); + dummy = fwrite(str, l, 1, out); str += l; } if (!*str) @@ -680,6 +681,7 @@ int conf_write_autoconf(void) FILE *out, *tristate, *out_h; time_t now; int i, l; + size_t dummy; sym_clear_all_valid(); @@ -756,8 +758,8 @@ int conf_write_autoconf(void) while (1) { l = strcspn(str, "\"\\"); if (l) { - fwrite(str, l, 1, out); - fwrite(str, l, 1, out_h); + dummy = fwrite(str, l, 1, out); + dummy = fwrite(str, l, 1, out_h); str += l; } if (!*str) diff --git a/scripts/kconfig/expr.c b/scripts/kconfig/expr.c index d83f232..99a058d 100644 --- a/scripts/kconfig/expr.c +++ b/scripts/kconfig/expr.c @@ -1087,7 +1087,8 @@ void expr_print(struct expr *e, void (*fn)(void *, struct symbol *, const char * static void expr_print_file_helper(void *data, struct symbol *sym, const char *str) { - fwrite(str, strlen(str), 1, data); + size_t dummy; + dummy = fwrite(str, strlen(str), 1, data); } void expr_fprint(struct expr *e, FILE *out)