Re: pg_read_file() with virtual files returns empty string - Mailing list pgsql-hackers

From Joe Conway
Subject Re: pg_read_file() with virtual files returns empty string
Date
Msg-id e74d13ef-be38-c5dc-26ac-8c83d6cc32a3@joeconway.com
Whole thread Raw
In response to Re: pg_read_file() with virtual files returns empty string  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: pg_read_file() with virtual files returns empty string
List pgsql-hackers
On 7/2/20 6:29 PM, Tom Lane wrote:
> Joe Conway <mail@joeconway.com> writes:
>> On 7/2/20 5:37 PM, Tom Lane wrote:
>>> I still can't get excited about contorting the code to remove that
>>> issue.
>
>> It doesn't seem much worse than the oom test that was there before -- see attached.
>
> Personally I would not bother, but it's your patch.

Thanks, committed that way, ...

>> Are we in agreement that whatever gets pushed should be backpatched through pg11
>> (see start of thread)?
>
> OK by me.

... and backpatched to v11.

I changed the new error message to "file length too large" instead of "requested
length too large" since that seems more descriptive of what is actually
happening there. I also changed the corresponding error code to match the one
enlargeStringInfo() would have used because I thought it was more apropos.

Thanks for all the help with this!

Joe

--
Crunchy Data - http://crunchydata.com
PostgreSQL Support for Secure Enterprises
Consulting, Training, & Open Source Development


Attachment

pgsql-hackers by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: POC: rational number type (fractions)
Next
From: Tom Lane
Date:
Subject: Re: warnings for invalid function casts