aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/async.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2020-09-05 13:17:32 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2020-09-05 13:17:32 -0400
commita5cc4dab6d1d694f113912a2aca7012a95262f0b (patch)
tree73f084898fcefb8a93a10972721c0826fd2d6e0e /src/backend/commands/async.c
parent8febfd1855450f50f17419def41c2ea9bcf994d5 (diff)
downloadpostgresql-a5cc4dab6d1d694f113912a2aca7012a95262f0b.tar.gz
postgresql-a5cc4dab6d1d694f113912a2aca7012a95262f0b.zip
Yet more elimination of dead stores and useless initializations.
I'm not sure what tool Ranier was using, but the ones I contributed were found by using a newer version of scan-build than I tried before. Ranier Vilela and Tom Lane Discussion: https://postgr.es/m/CAEudQAo1+AcGppxDSg8k+zF4+Kv+eJyqzEDdbpDg58-=MQcerQ@mail.gmail.com
Diffstat (limited to 'src/backend/commands/async.c')
-rw-r--r--src/backend/commands/async.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/backend/commands/async.c b/src/backend/commands/async.c
index 774b26fd2c4..cb341365df4 100644
--- a/src/backend/commands/async.c
+++ b/src/backend/commands/async.c
@@ -1918,7 +1918,6 @@ static void
asyncQueueReadAllNotifications(void)
{
volatile QueuePosition pos;
- QueuePosition oldpos;
QueuePosition head;
Snapshot snapshot;
@@ -1933,7 +1932,7 @@ asyncQueueReadAllNotifications(void)
LWLockAcquire(NotifyQueueLock, LW_SHARED);
/* Assert checks that we have a valid state entry */
Assert(MyProcPid == QUEUE_BACKEND_PID(MyBackendId));
- pos = oldpos = QUEUE_BACKEND_POS(MyBackendId);
+ pos = QUEUE_BACKEND_POS(MyBackendId);
head = QUEUE_HEAD;
LWLockRelease(NotifyQueueLock);