Wrong dead return value in jsonb_utils.c - Mailing list pgsql-hackers

From Rikard Falkeborn
Subject Wrong dead return value in jsonb_utils.c
Date
Msg-id CADRDgG7mJnek6HNW13f+LF6V=6gag9PM+P7H5dnyWZAv49aBGg@mail.gmail.com
Whole thread Raw
Responses Re: Wrong dead return value in jsonb_utils.c
List pgsql-hackers
Returning -1 from a function with bool as return value is the same as returning true. Now, the code is dead (since elog(ERROR, ...) does not return) so it doesn't matter to the compiler, but changing to false is less confusing for the programmer. Appologies if this is seen as unnecessary churn.

The same code is present since 9.4, but perhaps it's not really worth backporting since it is more of an aesthetic change?
Attachment

pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: Bug in reindexdb's error reporting
Next
From: Noah Misch
Date:
Subject: Re: Augment every test postgresql.conf