Content-Length: 259201 | pFad | http://github.com/postgrespro/postgres/commit/3c702b3ed1519624d50e7a42283b8d481a579f77

45 Explicitly ignore guaranteed-true result from pgstat_lock_entry(). · postgrespro/postgres@3c702b3 · GitHub
Skip to content

Commit 3c702b3

Browse files
committed
Explicitly ignore guaranteed-true result from pgstat_lock_entry().
With nowait passed as false, pgstat_lock_entry() must return true so there's no need to check its result. Coverity seems unconvinced of this, so whack it upside the head with a (void) cast.
1 parent 93fcf2d commit 3c702b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend/utils/activity/pgstat_shmem.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -920,7 +920,7 @@ pgstat_reset_entry(PgStat_Kind kind, Oid dboid, Oid objoid, TimestampTz ts)
920920
if (!entry_ref || entry_ref->shared_entry->dropped)
921921
return;
922922

923-
pgstat_lock_entry(entry_ref, false);
923+
(void) pgstat_lock_entry(entry_ref, false);
924924
shared_stat_reset_contents(kind, entry_ref->shared_stats, ts);
925925
pgstat_unlock_entry(entry_ref);
926926
}

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres/commit/3c702b3ed1519624d50e7a42283b8d481a579f77

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy