hapostgres / pg_auto_failover

Postgres extension and service for automated failover and high-availability
Other
1.07k stars 113 forks source link

Avoid NULL pointer check #898

Closed danielgustafsson closed 2 years ago

danielgustafsson commented 2 years ago

prinaryNode is already dereferenced at this point so there is no need to recheck here. Remove the check and reuse the message buffer (with a reset) to simplify the code.