pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: vacuumdb: Don't assign negative values to a boolean.
2+ messages / 1 participants
[nested] [flat]

* pgsql: vacuumdb: Don't assign negative values to a boolean.
@ 2015-08-15 15:01 Andres Freund <andres@anarazel.de>
  0 siblings, 0 replies; 2+ messages in thread

From: Andres Freund @ 2015-08-15 15:01 UTC (permalink / raw)
  To: pgsql-committers

vacuumdb: Don't assign negative values to a boolean.

Since a17923204736 (vacuumdb: enable parallel mode) -1 has been assigned
to a boolean. That can, justifiedly, trigger compiler warnings. There's
also no need for ternary logic, result was only ever set to 0 or -1. So
don't.

Discussion: 20150812084351.GD8470@awork2.anarazel.de
Backpatch: 9.5

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/1d4bd77568493309914217251dce5bd51f4a72b7

Modified Files
--------------
src/bin/scripts/vacuumdb.c |    8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* pgsql: vacuumdb: Don't assign negative values to a boolean.
@ 2015-08-15 15:01 Andres Freund <andres@anarazel.de>
  0 siblings, 0 replies; 2+ messages in thread

From: Andres Freund @ 2015-08-15 15:01 UTC (permalink / raw)
  To: pgsql-committers

vacuumdb: Don't assign negative values to a boolean.

Since a17923204736 (vacuumdb: enable parallel mode) -1 has been assigned
to a boolean. That can, justifiedly, trigger compiler warnings. There's
also no need for ternary logic, result was only ever set to 0 or -1. So
don't.

Discussion: 20150812084351.GD8470@awork2.anarazel.de
Backpatch: 9.5

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/32951f9aa9acfd4b6318f6daf39c3d1c10a264ba

Modified Files
--------------
src/bin/scripts/vacuumdb.c |    8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2015-08-15 15:01 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-08-15 15:01 pgsql: vacuumdb: Don't assign negative values to a boolean. Andres Freund <andres@anarazel.de>
2015-08-15 15:01 pgsql: vacuumdb: Don't assign negative values to a boolean. Andres Freund <andres@anarazel.de>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox