From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E1E9DC4338F for ; Sun, 1 Aug 2021 17:53:48 +0000 (UTC) Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by mail.kernel.org (Postfix) with ESMTP id 5DFE560C40 for ; Sun, 1 Aug 2021 17:53:48 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 5DFE560C40 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nutanix.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dpdk.org Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7C1B940143; Sun, 1 Aug 2021 19:53:47 +0200 (CEST) Received: from sent.movementarian.org (unknown [88.98.93.30]) by mails.dpdk.org (Postfix) with ESMTP id B670140140 for ; Sun, 1 Aug 2021 19:53:45 +0200 (CEST) Received: from jlevon by sent.movementarian.org with local (Exim 4.93) (envelope-from ) id 1mAFeh-0003BC-Ps; Sun, 01 Aug 2021 18:53:43 +0100 From: John Levon To: dev@dpdk.org Cc: thomas@monjalon.net, kkanas@marvell.com, John Levon Date: Sun, 1 Aug 2021 18:53:25 +0100 Message-Id: <20210801175325.12163-1-john.levon@nutanix.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <11971053.QyrIl9gFXQ@thomas> References: <11971053.QyrIl9gFXQ@thomas> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH] app/test: quieten noise while forking 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 Sender: "dev" When closing file descriptors post-fork, ignore "." and ".." directory entries, so the test log doesn't have distracting errors like: Error converting name fd 0 .: Error converting name fd 0 ..: Signed-off-by: John Levon --- app/test/process.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/test/process.h b/app/test/process.h index 0ed91a939e..5b10cf64df 100644 --- a/app/test/process.h +++ b/app/test/process.h @@ -90,6 +90,11 @@ process_dup(const char *const argv[], int numargs, const char *env_value) } while ((dirent = readdir(dir)) != NULL) { + + if (strcmp(dirent->d_name, ".") == 0 || + strcmp(dirent->d_name, "..") == 0) + continue; + errno = 0; fd = strtol(dirent->d_name, &endptr, 10); if (errno != 0 || endptr[0] != '\0') { -- 2.25.1