Index: installer/src/installer-lib/process.cpp |
=================================================================== |
--- a/installer/src/installer-lib/process.cpp |
+++ b/installer/src/installer-lib/process.cpp |
@@ -280,9 +280,20 @@ |
default : |
Eric
2015/03/13 16:49:48
This should be "case 4 :" and we should retain the
|
/* |
- * We're out of ways to try to shut down. |
+ * We're out of ways to try to shut down. Oh well. Take cover. It gets violent here. |
Eric
2015/03/13 16:49:48
Good comment.
|
*/ |
- return false ; |
+ for (auto it = pid_set.begin(); it != pid_set.end(); ++it) |
+ { |
+ HANDLE tmpHandle = OpenProcess(PROCESS_TERMINATE, FALSE, *it); |
+ if (tmpHandle != NULL) |
Eric
2015/03/13 16:49:48
We can use implicit conversion to bool here.
I wo
|
+ { |
+ Windows_Handle procHandle(tmpHandle); |
+ TerminateProcess(tmpHandle, 0); |
+ } |
+ } |
+ Refresh(); |
+ |
+ return !IsRunning() ; |
} |
/* |
@@ -290,7 +301,7 @@ |
*/ |
for ( unsigned int j = 0 ; j < 50 ; ++ j ) |
{ |
- std::this_thread::sleep_for( std::chrono::milliseconds( 100 ) ) ; |
+ std::this_thread::sleep_for( std::chrono::milliseconds( 30 ) ) ; |
sergei
2015/04/02 08:04:09
no spaces?
|
Refresh() ; |
if ( ! IsRunning() ) |
{ |