Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0dRz-00083t-Nw for pgsql-hackers@arkaria.postgresql.org; Fri, 14 Sep 2018 02:03:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g0dRx-0007Pe-Ag for pgsql-hackers@arkaria.postgresql.org; Fri, 14 Sep 2018 02:03:13 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0dRx-0007PW-1m for pgsql-hackers@lists.postgresql.org; Fri, 14 Sep 2018 02:03:13 +0000 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0dRo-00025r-ON for pgsql-hackers@lists.postgresql.org; Fri, 14 Sep 2018 02:03:11 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 386A762E; Thu, 13 Sep 2018 22:03:02 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Thu, 13 Sep 2018 22:03:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=p01g3QxeHxWAsCrYboAPS0NQPxy0N1p75TxiK2V0jcs=; b=wzRfao1n Iri2gqHUVlfKgOFU9JJIHAjPJTV/NTniP64AWRk9Jj1+RRDPTheQ/JjHg62i46DN UpTZGbIDoYbe5EMBf2yn+DVBFg6Piu58ejPAPQFwEa2d6L3fqgzem4rZyKULVCUV 5/NeP+euMsrdD79M0pKXeNkj4n6SR9XZBqgsMTV+FOgE7D5TTJQZxkg13E3PrZn1 d9rnp5BBq746khVYmj91/jyfBLALpbO02Jl+OrWXOKX97fEX7Q3HnTo35cSEn94R AfM3/PQ5uzDOhdfC0/WiCxb7EfHUIBCUdjfs97EYDTc2xkVvF/cJCFgeH+BnEGyd lNAH8/ZKx83kEw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; bh=p01g3QxeHxWAsCrYboAPS0NQPxy0N 1p75TxiK2V0jcs=; b=U0U1GppRZ7EmUNzMuyR43XbK4BWhO1kZWQn1dM1zPEyiH +BGLQHGsZ3kuhT4QwVcfAUwqA8l1arrvrevp8CnjU8a32eWppFw8y4BJIscl2YNr y2lhJB6HxMfKof81pz7o1ET3AcUz+ENPMtztPsoHEoLTXaS26/lf19XIhc4kzNDu i8aViyDWn1Euh1UFEnSXW7no5f5C3G/FgjR+jMs3lHA+91aRs0H0AUBvapcG0M+7 TyL+mNJuJNKNwEc5L1HNp4sR37wnVs9nMFiSsamjjtd8/zUG9Kels27ScusymtiU OKNvkyU7abLwLw2cz6H3Q+N7DhO4+ngQbTeWl0Qhw== X-ME-Proxy: X-ME-Sender: Received: from paquier.xyz (mp76f1f83a.ap.nuro.jp [118.241.248.58]) by mail.messagingengine.com (Postfix) with ESMTPA id 421C2102D8; Thu, 13 Sep 2018 22:02:59 -0400 (EDT) Date: Fri, 14 Sep 2018 11:02:56 +0900 From: Michael Paquier To: Tom Lane Cc: Thomas Munro , Alvaro Herrera , PostgreSQL Hackers Subject: Re: Allowing printf("%m") only where it actually works Message-ID: <20180914020256.GD29332@paquier.xyz> References: <20180528150125.j2x3mp62ssbeg3h5@alvherre.pgsql> <2685.1527520461@sss.pgh.pa.us> <8770.1533931511@sss.pgh.pa.us> <16896.1533935042@sss.pgh.pa.us> <14925.1534040609@sss.pgh.pa.us> <1437.1534100930@sss.pgh.pa.us> <13183.1534624490@sss.pgh.pa.us> <30022.1534705920@sss.pgh.pa.us> <20180912070739.GK25160@paquier.xyz> <1304.1536774001@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="4zI0WCX1RcnW9Hbu" Content-Disposition: inline In-Reply-To: <1304.1536774001@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --4zI0WCX1RcnW9Hbu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 12, 2018 at 01:40:01PM -0400, Tom Lane wrote: > Michael Paquier writes: > > I would have liked to look at this patch in details, but it failed to > > apply. Could you rebase? >=20 > Ah, yeah, the dlopen patch touched a couple of the same places. > Rebase attached --- no substantive changes. - if (handleDLL =3D=3D NULL) - ereport(FATAL, - (errmsg_internal("could not load netmsg.dll: error - code %lu", GetLastError()))); In 0001, this is replaced by a non-FATAL error for the backend, which does not seem like a good idea to me because the user loses visibility with this DDL which canot be loaded. I still have to see this error... And about 0002. I am surprised by the amount of cleanup that the removal of all the special wrappers for %m gives, especially expand_fmt_string. So +1 for the concept. I have been testing both patches individually on Windows and compilation, as well as tests, do not show any issues. The tests have been done only with MSVC. Could you drop the configure checks for snprintf and vsnprintf in a separate patch? The cleanup of %m and the removal of those switches should be treated separatly in my opinion. -- Michael --4zI0WCX1RcnW9Hbu Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAlubFtAACgkQnvQgOdby QH3xnQ/9GhEsL8iHoriNAxflP9oNwQbe8lddumNdZM7RTRqfSSbSKbJMIjfnrk/Y zB58Zckk7pH0Y4QQeWEvOBnK+/3jRMCfnklJd4vExJsjEWyT2yaqPGt24S7c8fpk bnLiM2eEBpUteiYSZ2Nt2Xl/wJFRkqdh5FTW0vySEu7RyRMBTw//7vKWVbX1M6J/ iFzH1Lax1GI2d9WleyplBbPeHioOKdZz7jrIhefdSJj0Zwvkkq6z+Oa3mjHHEYio rfdclw1aj3xF4l06qHUoBsazq74arY8oU5k2HxZxQYMJjBsEuxU0VIc4+7QQs8Sq SZfvlKvfGYXqdu5KHHQPgYQbkP/W7yY4MuGZhooIMglcfWgY/w/xye9OfVRynWV4 QUWUezkDYbREGjrU8n9s4cwT4JTqX0pJKaencBq4tfTj0FNTmWVTvfQnpELCmr2B qJfn3+zGj5XC6M6FkKBxAAiLNQ5PnaTPNxL8o7Eau9O+t+XawYJAbEo2HTlBdQKt gVt2pjqQ0e/qE/1n/yGGBUdhHGWp1eN3JLBqxc31Tj/QESsKhbCrItXzNY5lIp1h mIfQ7tqvPV3gsohwGwM6N1a2ybE3mXjzhkklAGTzh3NKDxpaRiqxerSHhgkUkCAR NpoD5maqDZ/htjH6UFhnISd5s341S4zyu6xBOTiFxYkSLZOOBu4= =mPLE -----END PGP SIGNATURE----- --4zI0WCX1RcnW9Hbu--