On 2014-02-09 02:29:25 +0000, Stephen Frost wrote:
> Minor pg_dump improvements
> 
> Improve pg_dump by checking results on various fgetc() calls which
> previously were unchecked, ditto for ftello.  Also clean up a couple
> of very minor memory leaks by waiting to allocate structures until
> after the initial check(s).

This triggers clang to emit:

/home/andres/src/postgresql/src/bin/pg_dump/pg_backup_archiver.c:1950:32: 
warning: comparison of constant -1 with expression of type
      'ArchiveFormat' (aka 'enum _archiveFormat') is always false 
[-Wtautological-constant-out-of-range-compare]
                if ((AH->format = fgetc(fh)) == EOF)
                    ~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~
1 warning generated.

Greetings,

Andres Freund

-- 
 Andres Freund                     http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


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

Reply via email to