File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -794,7 +794,7 @@ public function getProcesses($forThisServer = false) {
794794 /**
795795 * Soft ending of a running job, e.g. when migration is starting
796796 *
797- * @param int $pid
797+ * @param string $pid
798798 * @return void
799799 */
800800 public function endProcess ($ pid ) {
Original file line number Diff line number Diff line change @@ -289,15 +289,15 @@ public function end($in = null) {
289289
290290 if ($ in === 'all ' || $ in === 'server ' ) {
291291 foreach ($ processes as $ process => $ timestamp ) {
292- $ this ->QueuedJobs ->endProcess (( int ) $ process );
292+ $ this ->QueuedJobs ->endProcess ($ process );
293293 }
294294
295295 $ this ->out ('All ' . count ($ processes ) . ' processes ended. ' );
296296
297297 return ;
298298 }
299299
300- $ this ->QueuedJobs ->endProcess (( int ) $ in );
300+ $ this ->QueuedJobs ->endProcess ($ in );
301301 }
302302
303303 /**
@@ -603,8 +603,9 @@ protected function _initPid() {
603603 * @return string
604604 */
605605 protected function _retrievePid () {
606- $ pid = (string )getmypid ();
607- if (!$ pid ) {
606+ if (function_exists ('posix_getpid ' )) {
607+ $ pid = (string )posix_getpid ();
608+ } else {
608609 $ pid = $ this ->QueuedJobs ->key ();
609610 }
610611
You can’t perform that action at this time.
0 commit comments