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 1g4pqZ-0007z8-1r for pgsql-hackers@arkaria.postgresql.org; Tue, 25 Sep 2018 16:05:59 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g4pqX-0006OP-8n for pgsql-hackers@arkaria.postgresql.org; Tue, 25 Sep 2018 16:05:57 +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 1g4pqX-0006OC-1u for pgsql-hackers@lists.postgresql.org; Tue, 25 Sep 2018 16:05:57 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g4pqQ-0006xz-PW for pgsql-hackers@lists.postgresql.org; Tue, 25 Sep 2018 16:05:56 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w8PG5gRx028379; Tue, 25 Sep 2018 12:05:42 -0400 From: Tom Lane To: Alvaro Herrera cc: Michael Paquier , Thomas Munro , PostgreSQL Hackers Subject: Re: Allowing printf("%m") only where it actually works In-reply-to: <20180925154829.rbjxmmcpd5z7ueyq@alvherre.pgsql> References: <20180925154829.rbjxmmcpd5z7ueyq@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Tue, 25 Sep 2018 12:48:29 -0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <28377.1537891542.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Tue, 25 Sep 2018 12:05:42 -0400 Message-ID: <28378.1537891542@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Alvaro Herrera writes: > On 2018-Sep-25, Tom Lane wrote: >> We could possibly write something like >> = >> sprintf(wserrbuf, "winsock error %d (could not load netmsg.dll to trans= late: error code %lu)", err, GetLastError()))); >> = >> but I'm unconvinced that that's useful. > Actually I think it *is* useful to do it like this, because then the > user knows to fix the netmsg.dll problem so that they can continue to > investigate the winsock problem. If we don't report the secondary error > message, how are users going to figure out how to fix the problem? OK, I'm fine with doing it like that if people want it. regards, tom lane