Re: Shouldn't execParallel.c null-terminate query_string in the parallel DSM?

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Rafia Sabih <rafia(dot)sabih(at)enterprisedb(dot)com>
Cc: Thomas Munro <thomas(dot)munro(at)enterprisedb(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Shouldn't execParallel.c null-terminate query_string in the parallel DSM?
Date: 2017-12-20 22:32:43
Message-ID: CA+TgmoafX7deorqO8PW+XEj4eXV5F8Sy_9d51PKudFLBWSY11A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Dec 20, 2017 at 2:03 AM, Rafia Sabih
<rafia(dot)sabih(at)enterprisedb(dot)com> wrote:
> On Wed, Dec 20, 2017 at 7:58 AM, Thomas Munro
> <thomas(dot)munro(at)enterprisedb(dot)com> wrote:
>> I just saw some trailing garbage in my log file emanating from a
>> parallel worker when my query happened to be a BUFFERALIGNed length
>> (in this case 64 characters). Did commit 4c728f382970 forget to make
>> sure the null terminator is copied? See attached proposed fix.
>>
> Yes, I missed that.
> Your patch looks good to me, thanks.

Sigh. I missed that too. Committed and back-patched to v10.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2017-12-20 22:35:03 Re: Tracking of page changes for backup purposes. PTRACK [POC]
Previous Message David Kamholz 2017-12-20 22:29:28 Re: domain cast in parameterized vs. non-parameterized query