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 23F24A0032; Fri, 29 Oct 2021 13:23:49 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A75B64111F; Fri, 29 Oct 2021 13:23:48 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id EF1E5410E1 for ; Fri, 29 Oct 2021 13:23:46 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1635506626; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=nuA9ATZTuMJ5/kZv77srkm/h79jZVugzNkV7xMPLqVM=; b=C6xFUAwjRkDo4cZF2vVf9Jg25QsK+YsNA/5nrdcGnteqhxh30Iuq/Jb7TCVNCNVy8euB25 sWIZEQpr2qw7VZUPEodS0gtqi5Pu7z6fAGDO1Y5JwDkz6YyTsMWZ1MRdIGf5UqPMA42DL9 +KpVcAS1vjviQ3ol5gLJYuWnS6hQF8w= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-416-vtcl0K_mN-yRphrzpRqC8g-1; Fri, 29 Oct 2021 07:23:42 -0400 X-MC-Unique: vtcl0K_mN-yRphrzpRqC8g-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C88AC5127; Fri, 29 Oct 2021 11:23:41 +0000 (UTC) Received: from dmarchan.remote.csb (unknown [10.40.192.79]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2558B6911C; Fri, 29 Oct 2021 11:23:39 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: Olivier Matz , Dmitry Kozlyuk , Zhihong Peng Date: Fri, 29 Oct 2021 13:23:15 +0200 Message-Id: <20211029112315.25748-1-david.marchand@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=david.marchand@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII" Subject: [dpdk-dev] [PATCH] test/cmdline: fix memory leak 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" Previous change wrongly removed a valid cmdline_free(). Fixes: 6ad06203a587 ("cmdline: free on exit") Signed-off-by: David Marchand --- app/test/test_cmdline_lib.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/test/test_cmdline_lib.c b/app/test/test_cmdline_lib.c index f238094b07..f50ccdb599 100644 --- a/app/test/test_cmdline_lib.c +++ b/app/test/test_cmdline_lib.c @@ -176,6 +176,8 @@ test_cmdline_socket_fns(void) printf("Error: failed to open /dev/null for reading!"); return -1; } + cmdline_free(cl); + cl = NULL; /* void functions */ cmdline_stdin_exit(NULL); -- 2.23.0