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 BB52F48B34 for ; Mon, 17 Nov 2025 18:53:47 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 21C37402D5; Mon, 17 Nov 2025 18:53:45 +0100 (CET) Received: from mail-pg1-f171.google.com (mail-pg1-f171.google.com [209.85.215.171]) by mails.dpdk.org (Postfix) with ESMTP id 13919402C8 for ; Mon, 17 Nov 2025 18:53:42 +0100 (CET) Received: by mail-pg1-f171.google.com with SMTP id 41be03b00d2f7-bd1b0e2c1eeso838122a12.0 for ; Mon, 17 Nov 2025 09:53:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1763402021; x=1764006821; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=mXZCR3XunXP4p5rpPhXduq6BNn5K6SADN6bWzRaKasU=; b=UEEKmBNAOk/8xktdQ1ePT8gSablDo13JhJ/NBIfamrQIBE1UIA3bPJAB6HFKqfBeSC GUYeJWEyjH9JUYWFd/w0qgWqCipS+PDK/5rgNQIjpK2mBQL7MQ1yHSA1K1IPCIGJyYm6 KhnicVNvJH7lTmn6LBRfXP8HGjPG4wxnoeATdyTDMp06BO6e80NPsW/B/Oi3OI13rk8U vSNyyORVHR0nv7qLWzOANYAAjD72JmlSLTrmLdBdZ9JIDxXyxHwAJi2FI6fbJ6hWjjEB QoiUQ4Up9/ZP4SZwhDJCgYEkwjJa/BA3ROv0ezd7pELii+0U8xaMvVW1EzvLnbjdoAiB pQOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763402021; x=1764006821; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=mXZCR3XunXP4p5rpPhXduq6BNn5K6SADN6bWzRaKasU=; b=Kw5xQ+cHJK6fQZ4mb/eh05RyR37ROyjf/HhBNy0R3ZeezcBVTt8g2qfDdogAC3vyZg F9W3C9ifxyA+c6MXeoT/FTQs+y6DIq8fvo9gf0a/G5KeQNT1u29sJwh6f5vLgdu1X1/2 3YT9+7Omb0DR3LTR07c8KvmsWMZ/B9oaBxX3fM01juimjyGc/2RUO+xosu21BloAKjwb c9Qj3KyMkIWw4kfBKNv9ZWGTJc/p9vn5dChPZe4KUZKSjCkWrT5BeCJ4u4A0kTQvaW8O sqscvYW+dWOlHkQq7lxnhNqobAotfO04YKE8eg146kkwhaOCb1pZ5uVSnXC73IwQiv8z S6bA== X-Forwarded-Encrypted: i=1; AJvYcCXZk7Z//GPeLeyypD8fSNGRqJsGjwu9ZpZy9CbzaF+9jkecrvHYZEFi5FlnTfRbZGo2SdvOYJ8=@dpdk.org X-Gm-Message-State: AOJu0YzF1Qw155d6E7VGbmiUbptg6y0cUFLExSiqGEs8SVoQvpyVmuEf c3CSFlihpLVC/wnA2syaZGAPI6AaCngMT1wI5KZSi9x6z2sY2U3cCGWnfXid/RLxfek= X-Gm-Gg: ASbGnct272dy0sDEFNLNz1twx7+QVBgwwczMmQgLt8I49w1Id2CXkwvX3cLha2D59EQ FiKuoTPM4Ww4yXxDRJ/zJpoAgqZjCeOcTi2fa4aVogAddMP9rp1RkPHv9Qw3mekMB9tvv5Sjw7z LmDgRia+iSzmMfqRXYg8KXlobTpK49X0P2WPU/GyXbwW/xguAWOgXPyFgc2qGJTMIMejYMwQ/w4 45vrE19UyB6WO/LW6hj8hp2H0sUgTjFPUuxaa6NRH5S5QaDeszhxBZNUQmgNT9NORC3thSCkap4 NFH7Hee2EKWZpMSumM8Q3HE6l+hlGsD6NNab3FoNxsjOh0xSFgwnbDkk5whZpQKCst31EjusC0g AIKya61BLOAWW5PJ/JrfjPW69tMcVvaeoF5gUg0GgbZGB7LpjHXjcub6Bm6PWw6owJmkNqMP+ae wPr3lRs+wOSKJ8I4sKVtPWuk66jwborHUUuHx54JCf9AzZ6ZfLJafnvfUv9ljw X-Google-Smtp-Source: AGHT+IHxgiotvqmIoNqipm/rlfAc0o7mNwp8xFMc4gUc554mf83KwS0RloPD/39d9Z/Ea/xXnNxGKQ== X-Received: by 2002:a05:693c:630e:b0:2a4:3593:c7e0 with SMTP id 5a478bee46e88-2a4abd4b7fcmr5785096eec.32.1763402021133; Mon, 17 Nov 2025 09:53:41 -0800 (PST) Received: from phoenix.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 5a478bee46e88-2a49d9ead79sm63457494eec.1.2025.11.17.09.53.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Nov 2025 09:53:40 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , stable@dpdk.org, Cristian Dumitrescu , Bruce Richardson Subject: [PATCH v3 5/6] test: fix impossible format-truncation in cfgfiles Date: Mon, 17 Nov 2025 09:52:12 -0800 Message-ID: <20251117175332.14014-6-stephen@networkplumber.org> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251117175332.14014-1-stephen@networkplumber.org> References: <20251115193409.99740-1-stephen@networkplumber.org> <20251117175332.14014-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Although, it is not possible on Linux (which always uses /tmp) the compiler complains about possible snprintf() truncation. Simplest fix is to just increase the size of the filename variable. Fixes: be22019a58c4 ("test: restore cfgfile tests") Cc: stable@dpdk.org Signed-off-by: Stephen Hemminger --- app/test/test_cfgfile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test/test_cfgfile.c b/app/test/test_cfgfile.c index b189d9d7a5..823b48e1fa 100644 --- a/app/test/test_cfgfile.c +++ b/app/test/test_cfgfile.c @@ -148,7 +148,7 @@ static int test_cfgfile_realloc_sections(void) { struct rte_cfgfile *cfgfile; - char filename[PATH_MAX]; + char filename[PATH_MAX + NAME_MAX]; int ret; const char *value; -- 2.51.0