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 1lKNnW-0008MY-1m for pgsql-general@arkaria.postgresql.org; Thu, 11 Mar 2021 16:04:26 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lKNnV-0003t1-0R for pgsql-general@arkaria.postgresql.org; Thu, 11 Mar 2021 16:04:25 +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 1lKNnU-0003ru-PY for pgsql-general@lists.postgresql.org; Thu, 11 Mar 2021 16:04:24 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lKNnP-000738-1t for pgsql-general@lists.postgresql.org; Thu, 11 Mar 2021 16:04:23 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 12BG4HdM2293595; Thu, 11 Mar 2021 11:04:17 -0500 From: Tom Lane To: Niko Ware cc: pgsql-general@lists.postgresql.org Subject: Re: Example 31-2. libpq Example Program 2 In-reply-to: References: Comments: In-reply-to Niko Ware message dated "Thu, 11 Mar 2021 06:25:38 +0100" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <2293593.1615478657.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Thu, 11 Mar 2021 11:04:17 -0500 Message-ID: <2293594.1615478657@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Niko Ware writes: > I modified the code to include the "extra" member in the following > statement: > fprintf(stderr, > "ASYNC NOTIFY of '%s' received from backend PID %d: = %s\n", > notify->relname, notify->be_pid, *notify->extra*); > Both the example and my application core on an invalid address for "extr= a". Modifying testlibpq2.c like that works for me, FWIW. I speculate maybe you have a macro definition of "extra" that is bollixing things somehow? Kind of a weak theory, but nothing else comes to mind. regards, tom lane