Skip to content

Commit 5ed9dbe

Browse files
committed
merged branch Tobion/patch-2 (PR symfony#4080)
Commits ------- 9f0daf4 put parentheses back 885104c fix typo Discussion ---------- fix typo Fix typo introduced in symfony#4069 Past participle of `read` is `read`
2 parents 674cbf9 + 9f0daf4 commit 5ed9dbe

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/Symfony/Component/Process/Process.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ class Process
4848
private $status = self::STATUS_READY;
4949

5050
private $fileHandles;
51-
private $readedBytes;
51+
private $readBytes;
5252

5353
/**
5454
* Exit codes translation table.
@@ -274,7 +274,7 @@ public function start($callback = null)
274274
foreach ($fh as $type => $fileHandle) {
275275
fseek($fileHandle, 0);
276276
$data = fread($fileHandle, 8192);
277-
$this->readedBytes[$type] = strlen($data);
277+
$this->readBytes[$type] = strlen($data);
278278
if (strlen($data) > 0) {
279279
call_user_func($callback, $type == 1 ? self::OUT : self::ERR, $data);
280280
}
@@ -337,12 +337,12 @@ public function wait($callback = null)
337337
if (defined('PHP_WINDOWS_VERSION_BUILD')) {
338338
$fh = $this->fileHandles;
339339
foreach ($fh as $type => $fileHandle) {
340-
fseek($fileHandle, $this->readedBytes[$type]);
340+
fseek($fileHandle, $this->readBytes[$type]);
341341
$data = fread($fileHandle, 8192);
342-
if(isset($this->readedBytes)) {
343-
$this->readedBytes[$type] += strlen($data);
342+
if(isset($this->readBytes)) {
343+
$this->readBytes[$type] += strlen($data);
344344
} else {
345-
$this->readedBytes[$type] = strlen($data);
345+
$this->readBytes[$type] = strlen($data);
346346
}
347347

348348
if (strlen($data) > 0) {
@@ -719,7 +719,7 @@ protected function updateErrorOutput()
719719
protected function updateOutput()
720720
{
721721
if (defined('PHP_WINDOWS_VERSION_BUILD') && isset($this->fileHandles[self::STDOUT]) && is_resource($this->fileHandles[self::STDOUT])) {
722-
fseek($this->fileHandles[self::STDOUT], $this->readedBytes[self::STDOUT]);
722+
fseek($this->fileHandles[self::STDOUT], $this->readBytes[self::STDOUT]);
723723
$this->addOutput(stream_get_contents($this->fileHandles[self::STDOUT]));
724724
} elseif (isset($this->pipes[self::STDOUT]) && is_resource($this->pipes[self::STDOUT])) {
725725
$this->addOutput(stream_get_contents($this->pipes[self::STDOUT]));

0 commit comments

Comments
 (0)