From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C3C0343B7D; Thu, 29 Feb 2024 22:32:15 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C778A42F23; Thu, 29 Feb 2024 22:32:10 +0100 (CET) Received: from linux.microsoft.com (linux.microsoft.com [13.77.154.182]) by mails.dpdk.org (Postfix) with ESMTP id 0A6FB42DEA for ; Thu, 29 Feb 2024 22:32:08 +0100 (CET) Received: by linux.microsoft.com (Postfix, from userid 1086) id 0D7F820B74C3; Thu, 29 Feb 2024 13:32:06 -0800 (PST) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 0D7F820B74C3 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1709242327; bh=6MQpnBBH7z48vEx5t8YSsZ4pvK9yEpwal57ymng/mJg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=isZsYiakgylpdrXXeqhH4nDowo3zdHbZKYpEpJd3Dg7V0ht36mTo83LJKsM6D/+aJ 8MRFE+JCFnuYODGfUfg/qg5GXi82WMYD+VW7w/iMELwzXc8d8RVe34JZckwPUhwY2G ri/cmgOZThiv0dAeqg8bDqK715mAgJZuFfN8VwJo= From: Tyler Retzlaff To: dev@dpdk.org Cc: Anatoly Burakov , Ashish Gupta , Chenbo Xia , Cristian Dumitrescu , David Hunt , Fan Zhang , Hemant Agrawal , Honnappa Nagarahalli , Jasvinder Singh , Jerin Jacob , Konstantin Ananyev , Maxime Coquelin , Reshma Pattan , Sachin Saxena , Sivaprasad Tummala , Srikanth Yalavarthi , Stephen Hemminger , Sunil Kumar Kori , bruce.richardson@intel.com, mb@smartsharesystems.com, thomas@monjalon.net, Tyler Retzlaff Subject: [PATCH v5 03/22] cmdline: stop using variadic argument pack extension Date: Thu, 29 Feb 2024 13:31:46 -0800 Message-Id: <1709242325-17218-4-git-send-email-roretzla@linux.microsoft.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1709242325-17218-1-git-send-email-roretzla@linux.microsoft.com> References: <1707774557-16012-1-git-send-email-roretzla@linux.microsoft.com> <1709242325-17218-1-git-send-email-roretzla@linux.microsoft.com> X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Remove use of args... and just use __VA_ARGS__. The macros expanding the argument pack do not require args extension to remove trailing comma. Signed-off-by: Tyler Retzlaff --- lib/cmdline/cmdline_parse.c | 2 +- lib/cmdline/cmdline_parse_num.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/cmdline/cmdline_parse.c b/lib/cmdline/cmdline_parse.c index b6d6dac..76a212d 100644 --- a/lib/cmdline/cmdline_parse.c +++ b/lib/cmdline/cmdline_parse.c @@ -16,7 +16,7 @@ #ifdef RTE_LIBRTE_CMDLINE_DEBUG #define debug_printf printf #else -#define debug_printf(args...) do {} while(0) +#define debug_printf(...) do {} while (0) #endif #define CMDLINE_BUFFER_SIZE 64 diff --git a/lib/cmdline/cmdline_parse_num.c b/lib/cmdline/cmdline_parse_num.c index 820af07..e849878 100644 --- a/lib/cmdline/cmdline_parse_num.c +++ b/lib/cmdline/cmdline_parse_num.c @@ -14,9 +14,9 @@ #include "cmdline_parse_num.h" #ifdef RTE_LIBRTE_CMDLINE_DEBUG -#define debug_printf(args...) printf(args) +#define debug_printf(...) printf(__VA_ARGS__) #else -#define debug_printf(args...) do {} while(0) +#define debug_printf(...) do {} while (0) #endif struct cmdline_token_ops cmdline_token_num_ops = { -- 1.8.3.1