Skip to content

Commit eec08b9

Browse files
committed
[all] Removed call to getppid in SendPostmasterSignal, replacing with a
PostmasterPid variable, which gets set (early) in PostmasterMain getppid would not be the postmaster? [fork/exec] Implements processCancelRequest by keeping an array of pid/cancel_key structs in shared mem [fork/exec] Moves AttachSharedMemoryAndSemaphores call for backends into SubPostmasterMain [win32] Implements reaper/waitpid by keeping an arrays of children pids,handles in postmaster local mem - this item is largely untested, for reasons which should be obvious, but appears sound [win32/all] Added extern for pgpipe in Win32 case, and changed the second pipe call (which seems to have been missed earlier) to pgpipe [win32] #define'd ftruncate to chsize in the Win32 case [win32] PG_USLEEP for Win32 has a misplaced paren. Fixed. [win32] DLLIMPORT handling for MingW case Claudio Natoli
1 parent ede3b76 commit eec08b9

File tree

8 files changed

+266
-40
lines changed

8 files changed

+266
-40
lines changed

src/backend/postmaster/pgstat.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
*
1414
* Copyright (c) 2001-2003, PostgreSQL Global Development Group
1515
*
16-
* $PostgreSQL: pgsql/src/backend/postmaster/pgstat.c,v 1.55 2004/01/26 22:54:56 momjian Exp $
16+
* $PostgreSQL: pgsql/src/backend/postmaster/pgstat.c,v 1.56 2004/01/26 22:59:53 momjian Exp $
1717
* ----------
1818
*/
1919
#include "postgres.h"
@@ -147,7 +147,7 @@ static void pgstat_recv_resetcounter(PgStat_MsgResetcounter *msg, int len);
147147
#define piperead(a,b,c) read(a,b,c)
148148
#define pipewrite(a,b,c) write(a,b,c)
149149
#else
150-
/* pgpipe() is in /src/port */
150+
extern int pgpipe(int handles[2]); /* pgpipe() is in /src/port */
151151
#define piperead(a,b,c) recv(a,b,c,0)
152152
#define pipewrite(a,b,c) send(a,b,c,0)
153153
#endif
@@ -322,7 +322,7 @@ pgstat_init(void)
322322
/*
323323
* Create the pipe that controls the statistics collector shutdown
324324
*/
325-
if (pipe(pgStatPmPipe) < 0)
325+
if (pgpipe(pgStatPmPipe) < 0)
326326
{
327327
ereport(LOG,
328328
(errcode_for_socket_access(),

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy