Re: Use bool with synced field (src/include/replication/slot.h) - Mailing list pgsql-hackers

From Nathan Bossart
Subject Re: Use bool with synced field (src/include/replication/slot.h)
Date
Msg-id aLcVHXW2tyrLfTv8@nathan
Whole thread Raw
In response to Use bool with synced field (src/include/replication/slot.h)  (Ranier Vilela <ranier.vf@gmail.com>)
Responses Re: Use bool with synced field (src/include/replication/slot.h)
List pgsql-hackers
On Tue, Sep 02, 2025 at 09:47:49AM -0300, Ranier Vilela wrote:
> IMO in the struct ReplicationSlotPersistentData, the field *synced* has
> wrong type declaration. The intention was *bool* not *char* type.
> 
> Since it is only used in Boolean comparison.

LGTM.  In the original thread, it looks like this was added in v32 [0] and
effectively switched to a bool in v58 [1].

[0] https://postgr.es/m/CAJpy0uC2gYybBcvYCW68wvR-3akWnFbr7x66nZg7XTyjELW9iw%40mail.gmail.com
[1] https://postgr.es/m/OS0PR01MB57169DD55EC8D9D1EDB7A0C2946A2%40OS0PR01MB5716.jpnprd01.prod.outlook.com

-- 
nathan



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: psql client does not handle WSAEWOULDBLOCK on Windows
Next
From: Tom Lane
Date:
Subject: Re: Fixes a trivial bug in dumped parse/query/plan trees