Обсуждение: pgsql: Fix a race condition that I introduced into sinvaladt.c during

Поиск
Список
Период
Сортировка

pgsql: Fix a race condition that I introduced into sinvaladt.c during

От
tgl@postgresql.org (Tom Lane)
Дата:
Log Message:
-----------
Fix a race condition that I introduced into sinvaladt.c during the recent
rewrite.  When called from SIInsertDataEntries, SICleanupQueue releases
the write lock if it has to issue a kill() to signal some laggard backend.
That still seems like a good idea --- but it's possible that by the time
we get the lock back, there are no longer enough free message slots to
satisfy SIInsertDataEntries' requirement.  Must recheck, and repeat the
whole SICleanupQueue process if not.  Noted while reading code.

Modified Files:
--------------
    pgsql/src/backend/storage/ipc:
        sinvaladt.c (r1.73 -> r1.74)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/storage/ipc/sinvaladt.c?r1=1.73&r2=1.74)