"Lines 244-245 overwrite global variables `$runnerr` and `$runnerw` that
were already assigned in the child process (lines 205-206). In the
parent process context, these assignments appear incorrect and could
cause issues if `runner_init` is called multiple times. The parent
should only store references in the controller hashes."
It could never cause an actual issue, but clarifies the intent of the
code.
Spotted and fixed by GitHub Code Quality
Cherry-picked from #21646
Closes #21672
}
$controllerw{$thisrunnerid} = $thiscontrollerw;
- $runnerr = $thisrunnerr;
- $runnerw = $thisrunnerw;
+ if(!$multiprocess) {
+ $runnerr = $thisrunnerr;
+ $runnerw = $thisrunnerw;
+ }
$controllerr{$thisrunnerid} = $thiscontrollerr;
return $thisrunnerid;