From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 92AA340F42C for ; Sat, 7 Jan 2012 15:27:05 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" X-Spam-Flag: NO X-Spam-Score: -0.7 X-Spam-Level: X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 4CAh+osp4H9B for ; Sat, 7 Jan 2012 15:27:04 -0800 (PST) Received: from mail-ee0-f53.google.com (mail-ee0-f53.google.com [74.125.83.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 8A63540A927 for ; Sat, 7 Jan 2012 15:26:50 -0800 (PST) Received: by mail-ee0-f53.google.com with SMTP id d41so2133471eek.26 for ; Sat, 07 Jan 2012 15:26:50 -0800 (PST) Received: by 10.14.16.135 with SMTP id h7mr4133644eeh.19.1325978810170; Sat, 07 Jan 2012 15:26:50 -0800 (PST) Received: from localhost (dsl-hkibrasgw4-fe5cdc00-23.dhcp.inet.fi. [80.220.92.23]) by mx.google.com with ESMTPS id q67sm206816226eea.8.2012.01.07.15.26.48 (version=SSLv3 cipher=OTHER); Sat, 07 Jan 2012 15:26:49 -0800 (PST) From: Jani Nikula To: notmuch@notmuchmail.org Subject: [RFC PATCH 7/9] util: fix warning about variadic macros Date: Sun, 8 Jan 2012 01:26:21 +0200 Message-Id: <495872b788b4d851e18613372a12c063d3813197.1325977940.git.jani@nikula.org> X-Mailer: git-send-email 1.7.5.4 In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Jan 2012 23:27:06 -0000 lib/string-list.c: In function ‘_notmuch_string_list_sort’: lib/string-list.c:81:59: warning: ISO C99 requires rest arguments to be used [enabled by default] lib/message-file.c: In function ‘notmuch_message_file_restrict_headersv’: lib/message-file.c:147:90: warning: ISO C99 requires rest arguments to be used [enabled by default] Signed-off-by: Jani Nikula --- util/error_util.h | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/util/error_util.h b/util/error_util.h index bb15822..75709da 100644 --- a/util/error_util.h +++ b/util/error_util.h @@ -38,8 +38,10 @@ _internal_error (const char *format, ...) PRINTF_ATTRIBUTE (1, 2); * * Note that __location__ comes from talloc.h. */ -#define INTERNAL_ERROR(format, ...) \ - _internal_error (format " (%s).\n", \ - ##__VA_ARGS__, __location__) +#define _INTERNAL_ERROR(format, ...) \ + _internal_error (format "%s (%s).\n", \ + __VA_ARGS__, __location__) + +#define INTERNAL_ERROR(...) _INTERNAL_ERROR(__VA_ARGS__, "") #endif -- 1.7.5.4