From patchwork Thu Oct 20 03:21:01 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve Yang X-Patchwork-Id: 118737 X-Patchwork-Delegate: qi.z.zhang@intel.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 55FDCA0A04; Thu, 20 Oct 2022 05:31:28 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2B02142C7D; Thu, 20 Oct 2022 05:31:28 +0200 (CEST) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id BFA6642C31 for ; Thu, 20 Oct 2022 05:31:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1666236687; x=1697772687; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=d4R15riykpIBF0/29DJi644yOFaCrrWbISz/z+eiXew=; b=GmPzr13EKMAYog9YsOGVD2GU3I6C/aEzs4KHgyoyO5W9XqR58DPdNDwA XxAPeupME78KezIu0jIluIiE7ZWkxW2YBLOippg0w2wJSKSmnZGtp2+BN DR1aRke6XhhdvPcrCObCJp/SrhOZFHJCpF/ftV91iOMk8W0yKk+pYIpAj PHoPa0TDIaMzB5RAuQ/T7Ld6CTGr2NM4ZG1hMI+HV3de+ScRNrErtxl1X LXzjHnoiHMytIXfjtuEXR7hBW44Sd0kRidUWFTdMmxU7Sj45ScCiNHV30 0vKRTl39Pfu6kNx2TtRYFQmRsU+GVsJPtsipO1W/FjPtDTzCXJQuWf/qz A==; X-IronPort-AV: E=McAfee;i="6500,9779,10505"; a="368640538" X-IronPort-AV: E=Sophos;i="5.95,196,1661842800"; d="scan'208";a="368640538" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Oct 2022 20:31:25 -0700 X-IronPort-AV: E=McAfee;i="6500,9779,10505"; a="734553227" X-IronPort-AV: E=Sophos;i="5.95,196,1661842800"; d="scan'208";a="734553227" Received: from intel-cd-odc-steve.cd.intel.com ([10.240.178.206]) by fmsmga002-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Oct 2022 20:31:23 -0700 From: Steve Yang To: dev@dpdk.org Cc: qiming.yang@intel.com, qi.z.zhang@intel.com, Steve Yang Subject: [PATCH v1] net/ice: fix format overflow warning for meson build Date: Thu, 20 Oct 2022 03:21:01 +0000 Message-Id: <20221020032101.1932275-1-stevex.yang@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 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 ‘__builtin___sprintf_chk’ may write a terminating nul past the end of the destination [-Werror=format-overflow=] Enlarge string size to avoid this warning. Fixes: f2a3245e7aec ("net/ice: support ddp dump switch rule binary") Signed-off-by: Steve Yang Acked-by: Qi Zhang --- drivers/net/ice/ice_ddp_package.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ice/ice_ddp_package.c b/drivers/net/ice/ice_ddp_package.c index b881fa3ded..a27a4a2da2 100644 --- a/drivers/net/ice/ice_ddp_package.c +++ b/drivers/net/ice/ice_ddp_package.c @@ -445,7 +445,7 @@ ice_dump_switch(struct rte_eth_dev *dev, uint8_t **buff2, uint32_t *size) hw = ICE_DEV_PRIVATE_TO_HW(dev->data->dev_private); /* table index string format: "0000:" */ - #define TBL_IDX_STR_SIZE 6 + #define TBL_IDX_STR_SIZE 7 for (i = 0; i < ICE_BLK_MAX_COUNT; i++) { int res; uint16_t buff_size;