Comment #19 on issue 12343 by [email protected]: ProcessSingleton
Linux cleanups
http://code.google.com/p/chromium/issues/detail?id=12343
The following revision refers to this bug:
http://src.chromium.org/viewvc/chrome?view=rev&revision=22144
------------------------------------------------------------------------
r22144 | [email protected] | 2009-07-30 22:31:27 -0700 (Thu, 30 Jul 2009)
| 11 lines
Changed paths:
M
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/process_singleton.h?r1=22144&r2=22143
M
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/process_singleton_linux.cc?r1=22144&r2=22143
A
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/process_singleton_linux_uitest.cc
M
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/process_singleton_win.cc?r1=22144&r2=22143
M
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/chrome.gyp?r1=22144&r2=22143
It's a copy of http://codereview.chromium.org/155772, with the fix for
valgrind test failure.
This CL implements the second TODO item of issue 12343:
2) We should send back an ACK to the second process. If the second process
doesn't get an ACK in the given timeout, it should kill the first process
and go ahead and start.
The approach of this CL is to append process id to the singleton's socket
filename, such as "SingletonSocket-12345", and creates a symbol
link "SingletonSocket" to the real socket file. In
ProcessSingleton::NotifyOtherProcess() if it's successfully connected
to "SingletonSocket" but no ACK received, then the original process can be
killed by its process id retrieved from the symbol link.
BUG=http://crbug.com/12343 ProcessSingleton Linux cleanups
TEST=In one terminal, launch chrome and stop the process by pressing
ctrl-z, then launch chrome again in another terminal. The second chrome
shall be started in 5 seconds, and the first one shall be killed.
Review URL: http://codereview.chromium.org/160436
------------------------------------------------------------------------
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
--~--~---------~--~----~------------~-------~--~----~
Automated mail from issue updates at http://crbug.com/
Subscription options: http://groups.google.com/group/chromium-bugs
-~----------~----~----~----~------~----~------~--~---