BUG #18889: /src/backend/utils/adt/network.c condition is always false

Started by PG Bug reporting formabout 1 year ago2 messagesbugs
Jump to latest
#1PG Bug reporting form
noreply@postgresql.org

The following bug has been logged on the website:

Bug reference: 18889
Logged by: Daniel Elishakov
Email address: dan-eli@mail.ru
PostgreSQL version: 17.4
Operating system: Ubuntu 20.04
Description:

On line 282 there is a check of nb < 0, which is always false, so i think it
is better to be replaced with 'Assert(nb > 0);'

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: PG Bug reporting form (#1)
Re: BUG #18889: /src/backend/utils/adt/network.c condition is always false

PG Bug reporting form <noreply@postgresql.org> writes:

On line 282 there is a check of nb < 0, which is always false, so i think it
is better to be replaced with 'Assert(nb > 0);'

This one I do agree with getting rid of --- in fact, I don't
even see a need for an Assert. Done at f27eb0325.

regards, tom lane