Re: No error checking when reading from file using zstd in pg_dump - Mailing list pgsql-hackers

From Daniel Gustafsson
Subject Re: No error checking when reading from file using zstd in pg_dump
Date
Msg-id 1A6AF154-BFDE-4FFC-8153-B859DF9E509F@yesql.se
Whole thread Raw
In response to Re: No error checking when reading from file using zstd in pg_dump  (Tomas Vondra <tomas@vondra.me>)
List pgsql-hackers
> On 16 Jun 2025, at 21:45, Tomas Vondra <tomas@vondra.me> wrote:

> Regarding the Z_NULL, I believe it has always been ignored like this, at
> least since 9.1. The code simply returns what gzgets() returns, and then
> compares that to NULL, etc. Is there there's a better way to deal with
> Z_NULL? I suppose we could explicitly check/translate Z_NULL to NULL,
> although Z_NULL is simply defined as 0. I don't recall if NULL has some
> additional magic.

Right, to be clear, I don't think there is a bug here (or the risk one going
forward).  It's just my own preference of not mixing API concepts

--
Daniel Gustafsson




pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: No error checking when reading from file using zstd in pg_dump
Next
From: Nathan Bossart
Date:
Subject: Re: pg_dump --with-* options