From patchwork Fri May 8 11:23:56 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antonio Quartulli X-Patchwork-Id: 1108 Return-Path: Delivered-To: patchwork@openvpn.net Delivered-To: patchwork@openvpn.net Received: from director11.mail.ord1d.rsapps.net ([172.31.255.6]) by backend30.mail.ord1d.rsapps.net with LMTP id iPW0NjXOtV6INQAAIUCqbw for ; Fri, 08 May 2020 17:25:09 -0400 Received: from proxy18.mail.iad3b.rsapps.net ([172.31.255.6]) by director11.mail.ord1d.rsapps.net with LMTP id GASXMzXOtV6aUQAAvGGmqA ; Fri, 08 May 2020 17:25:09 -0400 Received: from smtp21.gate.iad3b ([172.31.255.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) by proxy18.mail.iad3b.rsapps.net with LMTP id 2Cy1LDXOtV7aWQAA3NpJmQ ; Fri, 08 May 2020 17:25:09 -0400 X-Spam-Threshold: 95 X-Spam-Score: 0 X-Spam-Flag: NO X-Virus-Scanned: OK X-Orig-To: openvpnslackdevel@openvpn.net X-Originating-Ip: [216.105.38.7] Authentication-Results: smtp21.gate.iad3b.rsapps.net; iprev=pass policy.iprev="216.105.38.7"; spf=pass smtp.mailfrom="openvpn-devel-bounces@lists.sourceforge.net" smtp.helo="lists.sourceforge.net"; dkim=fail (signature verification failed) header.d=sourceforge.net; dkim=fail (signature verification failed) header.d=sf.net; dmarc=none (p=nil; dis=none) header.from=unstable.cc X-Suspicious-Flag: YES X-Classification-ID: 64617f70-9172-11ea-b189-525400cdc90a-1-1 Received: from [216.105.38.7] ([216.105.38.7:58128] helo=lists.sourceforge.net) by smtp21.gate.iad3b.rsapps.net (envelope-from ) (ecelerity 4.2.38.62370 r(:)) with ESMTPS (cipher=DHE-RSA-AES256-GCM-SHA384) id 2D/71-26186-53EC5BE5; Fri, 08 May 2020 17:25:09 -0400 Received: from [127.0.0.1] (helo=sfs-ml-2.v29.lw.sourceforge.com) by sfs-ml-2.v29.lw.sourceforge.com with esmtp (Exim 4.90_1) (envelope-from ) id 1jXATo-0002Eo-Q2; Fri, 08 May 2020 21:24:24 +0000 Received: from [172.30.20.202] (helo=mx.sourceforge.net) by sfs-ml-2.v29.lw.sourceforge.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jXATo-0002Eh-5E for openvpn-devel@lists.sourceforge.net; Fri, 08 May 2020 21:24:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sourceforge.net; s=x; h=Content-Transfer-Encoding:MIME-Version:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=5YxEeOUGXRqrmLvNFS1TgAIxask50urR79rcR02YALs=; b=darpdQbUVKY/phTn2CYZ+EwW6a cmveLAtl+2OdKhP5gi0GgTxZDy0hf6/VckjFX2vgAlxmpI/Mb0hZnKdIwPMr3IjMtDAzZXpV82Lgo QpkrCCwacbTXE0sJWyhjK5ty1/eejiuEOpXF5VHOcuVlPvmv9CBj43afzTyKY4oomp2o=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject:Cc:To:From :Sender:Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post: List-Owner:List-Archive; bh=5YxEeOUGXRqrmLvNFS1TgAIxask50urR79rcR02YALs=; b=Y hQ0N106bFPwAsmhIY0QJOzQJDX7kbdyPLNVQAMGIS2AsKFM9nmA9xE8F1K8r1PnbcITbPFvyomc2Q 3ZQVaitFT1J3Uur6owdfFdkxTbUzSVkXQPm9DgX0LC6qIGfi39VC0C6j77qovwJZdMKQV5WntR/ZP DxvF8m7SzYLUhIxU=; Received: from s2.neomailbox.net ([5.148.176.60]) by sfi-mx-3.v28.lw.sourceforge.com with esmtps (TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256) (Exim 4.92.2) id 1jXATm-00DPd9-R8 for openvpn-devel@lists.sourceforge.net; Fri, 08 May 2020 21:24:24 +0000 From: Antonio Quartulli To: openvpn-devel@lists.sourceforge.net Date: Fri, 8 May 2020 23:23:56 +0200 Message-Id: <20200508212356.18522-1-a@unstable.cc> MIME-Version: 1.0 X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record -0.0 AWL AWL: Adjusted score from AWL reputation of From: address X-Headers-End: 1jXATm-00DPd9-R8 Subject: [Openvpn-devel] [PATCH] get rid of TAG_FILE_INLINE constant X-BeenThere: openvpn-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Antonio Quartulli Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox Now that the whole inline logic has been converted to using bool flags, the TAG_FILE_INLINE constant is not useful anymore. Get rid of the constant as it's now unused and to prevent any future developer from mistakenly use it again. Signed-off-by: Antonio Quartulli Acked-by: David Sommerseth --- to be applied after all other fixes, as they remove the few last usages of this constant. src/openvpn/common.h | 6 ------ src/openvpn/crypto.c | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/openvpn/common.h b/src/openvpn/common.h index 4e6f4809..623b3e0d 100644 --- a/src/openvpn/common.h +++ b/src/openvpn/common.h @@ -88,12 +88,6 @@ typedef unsigned long ptr_type; */ #define PUSH_REQUEST_INTERVAL 5 -/* - * A sort of pseudo-filename for data provided inline within - * the configuration file. - */ -#define INLINE_FILE_TAG "[[INLINE]]" - /* * Script security warning */ diff --git a/src/openvpn/crypto.c b/src/openvpn/crypto.c index 672aa14a..f1a52d8c 100644 --- a/src/openvpn/crypto.c +++ b/src/openvpn/crypto.c @@ -1189,7 +1189,7 @@ print_key_filename(const char *str, bool is_inline) { if (is_inline) { - return INLINE_FILE_TAG; + return "[[INLINE]]"; } return np(str);