Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pmtjO-00044P-8q for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Apr 2023 09:59:06 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pmtjN-000247-5D for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Apr 2023 09:59:05 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pmtjM-00023x-3q for pgsql-hackers@lists.postgresql.org; Thu, 13 Apr 2023 09:59:04 +0000 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pmtjF-0003FV-0C for pgsql-hackers@lists.postgresql.org; Thu, 13 Apr 2023 09:59:02 +0000 Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailout.west.internal (Postfix) with ESMTP id 2CB543200999; Thu, 13 Apr 2023 05:58:54 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Thu, 13 Apr 2023 05:58:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1681379933; x= 1681466333; bh=ilm1VE3MICOUTfLMwfnAu+HktyvefUdrpqVxZjivP44=; b=Z zexUm7iEWoMyn0M2loIzbP0n6p/PHrN3ibWfPCOL2IFpJCtt+lo2+XLv2EFsHO12 bh2pGZhhaBLRJr6RYDI6dEEdKNkbyZnvKAddaH+50DQZ6Iez9Uv5ua1GGy7WylNr co4826XR7STfAv6pqvRTVed7XwoH6603JWnph2ASO48jWBwhj1fG+kzKcqha8QUv jMuA4M0/6Olak4IsgQimeOLIRLwiVwmaBzbJ4QRMZtASZOZYxTY7Sw5MBkymxxti 6XBstjkZRMIjGJEf7G5i9Y3bpHwzs4iYz8FyxRPqCy3XEpnvJar+YydKTjzbmLnT HgR8hEvB4GoFX7I1p5K1g== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrvdekkedgvddvucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkgggtugfgjgesthekredttddtjeenucfhrhhomheptehlvhgr rhhoucfjvghrrhgvrhgruceorghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrgh eqnecuggftrfgrthhtvghrnhepgfdtgeelgefgffdtieduudffhfevkefgudefteehgfet hfekvdegjeelhfethedvnecuffhomhgrihhnpegvnhhtvghrphhrihhsvggusgdrtghomh dpphhoshhtghhrvghsqhhlrdhorhhgnecuvehluhhsthgvrhfuihiivgeptdenucfrrghr rghmpehmrghilhhfrhhomheprghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrgh X-ME-Proxy: Feedback-ID: ia2694551:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Thu, 13 Apr 2023 05:58:53 -0400 (EDT) Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id ABC46A1; Thu, 13 Apr 2023 11:58:51 +0200 (CEST) Date: Thu, 13 Apr 2023 11:58:51 +0200 From: Alvaro Herrera To: Michael Paquier Cc: Postgres hackers Subject: Re: Clean up hba.c of code freeing regexps Message-ID: <20230413095851.dflq5w3bss2gyus6@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2023-Apr-13, Michael Paquier wrote: > With db4f21e in place, there is no need to worry about explicitely > freeing any regular expressions that may have been compiled when > loading HBA or ident files because MemoryContextDelete() would be > able to take care of that now that these are palloc'd (the definitions > in regcustom.h superseed the ones of regguts.h). Hmm, nice. > The logic in hba.c that scans all the HBA and ident lines to any > regexps can be simplified a lot. Most of this code is new in 16~, so > I think that it is worth cleaning up this stuff now rather than wait > for 17 to open for business. Still, this is optional, and I don't > mind waiting for 17 if the regexp/palloc business proves to be an > issue during beta. I agree with the downthread votes to clean this up now rather than waiting. Also, you're adding exactly zero lines of new code, so I don't think feature freeze affects the decision. -- Álvaro Herrera Breisgau, Deutschland — https://www.EnterpriseDB.com/ "Once again, thank you and all of the developers for your hard work on PostgreSQL. This is by far the most pleasant management experience of any database I've worked on." (Dan Harris) http://archives.postgresql.org/pgsql-performance/2006-04/msg00247.php