提交 0ace923c 编写于 作者: M Magnus Hagander

Add pid to the pgident event name on win32.

Should fix a problem where two clusters are running under
two different service accounts and get colliding names,
causing only the first cluster to contain the pgident
event description.

Per report from Stephen Denne.
上级 0a4ef62b
......@@ -5,7 +5,7 @@
* to contain some useful information. Mechanism differs wildly across
* platforms.
*
* $PostgreSQL: pgsql/src/backend/utils/misc/ps_status.c,v 1.37 2008/01/01 19:45:54 momjian Exp $
* $PostgreSQL: pgsql/src/backend/utils/misc/ps_status.c,v 1.38 2008/01/31 09:21:17 mha Exp $
*
* Copyright (c) 2000-2008, PostgreSQL Global Development Group
* various details abducted from various places
......@@ -350,7 +350,7 @@ set_ps_display(const char *activity, bool force)
if (ident_handle != INVALID_HANDLE_VALUE)
CloseHandle(ident_handle);
sprintf(name, "pgident: %s", ps_buffer);
sprintf(name, "pgident(%d): %s", MyProcPid, ps_buffer);
ident_handle = CreateEvent(NULL, TRUE, FALSE, name);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册