Skip site navigation (1) Skip section navigation (2)

pgsql: Fix race condition in win32 signal handling.

From: mha(at)postgresql(dot)org (Magnus Hagander)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix race condition in win32 signal handling.
Date: 2010-01-31 17:16:29
Message-ID: 20100131171629.5C5047541B9@cvs.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
Log Message:
-----------
Fix race condition in win32 signal handling.

There was a race condition where the receiving pipe could be closed by the
child thread if the main thread was pre-empted before it got a chance to
create a new one, and the dispatch thread ran to completion during that time.

One symptom of this is that rows in pg_listener could be dropped under
heavy load.

Analysis and original patch by Radu Ilie, with some small
modifications by Magnus Hagander.

Tags:
----
REL8_4_STABLE

Modified Files:
--------------
    pgsql/src/backend/port/win32:
        signal.c (r1.22 -> r1.22.2.1)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/port/win32/signal.c?r1=1.22&r2=1.22.2.1)

pgsql-committers by date

Next:From: Magnus HaganderDate: 2010-01-31 17:18:28
Subject: pgsql: Remove now unnecessary loop around CallNamedPipe().
Previous:From: Magnus HaganderDate: 2010-01-31 17:16:27
Subject: pgsql: Fix race condition in win32 signal handling.

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group