Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tiRBR-00G0PM-CA for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Feb 2025 04:50:41 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tiRBP-001uyh-Bw for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Feb 2025 04:50:40 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tiRBP-001uyZ-2O for pgsql-hackers@lists.postgresql.org; Thu, 13 Feb 2025 04:50:39 +0000 Received: from fhigh-b7-smtp.messagingengine.com ([202.12.124.158]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tiRBO-000WDb-0j for pgsql-hackers@postgresql.org; Thu, 13 Feb 2025 04:50:38 +0000 Received: from phl-compute-09.internal (phl-compute-09.phl.internal [10.202.2.49]) by mailfhigh.stl.internal (Postfix) with ESMTP id B588C25401C8; Wed, 12 Feb 2025 23:50:37 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-09.internal (MEProxy); Wed, 12 Feb 2025 23:50:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm3; t=1739422237; x=1739508637; bh=NNT6BFFAcn Sd6hToghptF1wLzPFcCbg7yHkkb6qoudQ=; b=fNURDDyq1VczEcTcCQfNcmHK3V WmlhNlKLTQEVi2iQaDC+dyHz81sH4lVkdjsj/PFt2ATIhK1WQ7C6iQt49k9IPvYF 2eaqz5jK6d+6y39z+jdCvf6GgnPY1c72sAmBVT7eZlIIdfePSRlEJFWVT4ZcslEv SUtzVc7AJvuFD2hM/8VxPujbSGot/83vSNKuJIgUxUVsi5N4iXoBnooVYeGn0Prj 32GC6h66fhGjKi43veuaHBZtZfWJMLykRqr5llZCD4pTD9754kYgIaQpD+Vw6KUg ZOcTivf2kQJma5R4jcKqB6tpt00LeBg6FkUQpfJ3pY8eP1xOqHvDCR8J9vPg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t= 1739422237; x=1739508637; bh=NNT6BFFAcnSd6hToghptF1wLzPFcCbg7yHk kb6qoudQ=; b=whfWDF3CwQjqvNmP7g3zooqH6NtdXy3rgHO4XpzcgcE/WH45bDJ Y3BGlAntMz4WXiWja/ulwtL4ouZ0RqCXro4NgGg4oY3nW6n5Y6FvyMNI3+RsMZsj 5Ao0eb3O3nBrZnMkS7SP3eSsqAHHaicT/+J4sFRvDhn22/t+1adkMuM8Enw1m4oQ EszR0ZOx6WqIxzLL+EGL6zhK9vrtMUziieRc9bRr93N3073f0dVqzgbhiPdczgzf WAWSacPrGTaMg5AwKv7snqhFEXxgG3WxP4u960bCRhVJ4vN9J7givHSCKlmSHBot CPYuk3uVOFZrc9go6yYv4GIsirsFtkB4Z7w== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefvddrtddtgdegheekiecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdp uffrtefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivg hnthhsucdlqddutddtmdenfghrlhcuvffnffculdejtddmnecujfgurhepfffhvfevuffk fhggtggujgesghdtreertddtvdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrh cuoehmihgthhgrvghlsehprghquhhivghrrdighiiiqeenucggtffrrghtthgvrhhnpeet leeifedufffhhfdtteelgeeggeffhfekueevteeigfduudevudetgfegiedvjeenucevlh hushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehmihgthhgrvghl sehprghquhhivghrrdighiiipdhnsggprhgtphhtthhopeehpdhmohguvgepshhmthhpoh huthdprhgtphhtthhopehtghhlsehsshhsrdhpghhhrdhprgdruhhspdhrtghpthhtohep rghnughrvghssegrnhgrrhgriigvlhdruggvpdhrtghpthhtohepvghulhgvrhesvghulh gvrhhtohdrtghomhdprhgtphhtthhopehrrghnihgvrhdrvhhfsehgmhgrihhlrdgtohhm pdhrtghpthhtohepphhgshhqlhdqhhgrtghkvghrshesphhoshhtghhrvghsqhhlrdhorh hg X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 12 Feb 2025 23:50:35 -0500 (EST) Date: Thu, 13 Feb 2025 13:50:29 +0900 From: Michael Paquier To: Tom Lane Cc: Andres Freund , Euler Taveira , "ranier.vf@gmail.com" , pgsql-hackers Subject: Re: Small memory fixes for pg_createsubcriber Message-ID: References: <68d6d810-4ef1-4f62-b47f-89b21501249b@app.fastmail.com> <3337507.1739376124@sss.pgh.pa.us> <3490963.1739405311@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="UOLEDxfCOHLeIiZF" Content-Disposition: inline In-Reply-To: <3490963.1739405311@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --UOLEDxfCOHLeIiZF Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Feb 12, 2025 at 07:08:31PM -0500, Tom Lane wrote: > I spent a little time earlier today seeing what I could do with the > use-dmalloc patch I posted earlier. It turns out you can get through > initdb after s/free/PQfreemem/ in just two places, and then the > backend works fine. But psql is a frickin' disaster --- there's > free's of strings made with PQExpBuffer all over its backslash-command > handling, and no easy way to clean it up. Maybe other clients will > be less of a mess, but I'm not betting on that. Hmm. Okay. It sounds like it would be better to group everything that has been pointed together towards what should be a more generic solution than what I have posted. So I am holding on touching anything. -- Michael --UOLEDxfCOHLeIiZF Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmetehUACgkQnvQgOdby QH06MA//XVpjbbKz8/c76wIUZnIMdSbxzbdLrvCvyK9nHWsximl6MA2p7lruRawe bvjBQySte/wgjEFPQcr3C9qexGXphWWThKbbPj41ll73m6IFn/7K+hCejr6tD6i9 /QB84UVK8/MROFE6ZgAwlSO6bx/hFZac4oqywRUaPSzici59fe6bVdQUQTj+Vq8z R0vcgWEZeFudNXwnHK29CijLyEeYKLNYxbysAYo2B/45zLmFfi90AF8ryd9xBOhs af6ZQPrn3O9jXacBVZWEP8aOEnT5v3kA4PUjB7gPjhlhw/QDi5lCqqeKKK1voQJ7 sv9laSMvq3pMZmQkvmYAYy/kHWOMfsSVwsvbgFrczumO1kVs/IzH7K0fio0W1Ikr eoEBefjzTw6aBBHtCBUbRn4rsVyS9L6nAEI+hJcwB7HP+VLLLa+n7FVZOwGdS5wK 2kaIJxN0F541GVejwG2A0wnhj56i6y/5GTNTPdg2fxYnWrmZ3k86oKdszylmv+Zz 3ow5AU/XSQCb3QI7TX8D+pbpe4QvNB50JPmfgmuufDrXzibPZOjnH/QhUXfUl+0w tVDBLMggT7StVV/ni+I+GUHZeAeGKodbb4TeQguQu1v0bx6TJP7tow/F5CA0qNJr 9sGUYDkChgCnvfwh0QKz467ywXiXBg6FSPHXWArer1uYgAkba8A= =dYx7 -----END PGP SIGNATURE----- --UOLEDxfCOHLeIiZF--