Small miscellaneus fixes (Part II) - Mailing list pgsql-hackers

From Ranier Vilela
Subject Small miscellaneus fixes (Part II)
Date
Msg-id CAEudQAp2R2fbbi0OHHhv_n4=Ch0t1VtjObR9YMqtGKHJ+faUFQ@mail.gmail.com
Whole thread Raw
Responses Re: Small miscellaneus fixes (Part II)
List pgsql-hackers
Hi.

There another assorted fixes to the head branch.

1. Avoid useless pointer increment (src/backend/utils/activity/pgstat_shmem.c)
The pointer *p, is used in creation dsa memory,
not p + MAXALIGN(pgstat_dsa_init_size()).

2. Discard result unused (src/backend/access/transam/xlogrecovery.c)
Some compilers raise warnings about discarding return from strtoul.

3. Fix dead code (src/bin/pg_dump/pg_dump.c)
tbinfo->relkind == RELKIND_MATVIEW is always true, so "INDEX"
is never hit.
Per Coverity.

4. Fix dead code (src/backend/utils/adt/formatting.c)
Np->sign == '+', is different than "!= '-'" and is different than "!= '+'"
So the else is never hit.
Per Coverity.

5. Use boolean operator with boolean operands (b/src/backend/commands/tablecmds.c)

regards,
Ranier Vilela
Attachment

pgsql-hackers by date:

Previous
From: Pavel Borisov
Date:
Subject: Re: Use fadvise in wal replay
Next
From: Pavel Borisov
Date:
Subject: Re: Use fadvise in wal replay