minor #21855 SCA with Php Inspections (EA Extended) (kalessil)

This PR was merged into the 2.7 branch.

Discussion
----------

SCA with Php Inspections (EA Extended)

| Q             | A
| ------------- | ---
| Branch?       | 2.7
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

e1773ee Static code analysis with Php Inspections (EA Extended): dead code dropped, couple bugs fixed
This commit is contained in:
Nicolas Grekas 2017-03-04 10:49:48 +01:00
commit 5898ec2c5e
4 changed files with 2 additions and 4 deletions

View File

@ -94,6 +94,6 @@ class TimeZoneTransformer extends Transformer
return 'Etc/GMT'.($hours !== 0 ? $signal.$hours : '');
}
throw new \InvalidArgumentException('The GMT time zone \'%s\' does not match with the supported formats GMT[+-]HH:MM or GMT[+-]HHMM.');
throw new \InvalidArgumentException(sprintf("The GMT time zone '%s' does not match with the supported formats GMT[+-]HH:MM or GMT[+-]HHMM.", $formattedTimeZone));
}
}

View File

@ -162,7 +162,6 @@ class Process
$this->setTimeout($timeout);
$this->useFileHandles = '\\' === DIRECTORY_SEPARATOR;
$this->pty = false;
$this->enhanceWindowsCompatibility = true;
$this->enhanceSigchildCompatibility = '\\' !== DIRECTORY_SEPARATOR && $this->isSigchildEnabled();
$this->options = array_replace(array('suppress_errors' => true, 'binary_pipes' => true), $options);
}

View File

@ -206,7 +206,7 @@ class DigestData
} elseif ('auth' === $this->elements['qop']) {
$digest .= ':'.$this->elements['nc'].':'.$this->elements['cnonce'].':'.$this->elements['qop'];
} else {
throw new \InvalidArgumentException('This method does not support a qop: "%s".', $this->elements['qop']);
throw new \InvalidArgumentException(sprintf('This method does not support a qop: "%s".', $this->elements['qop']));
}
$digest .= ':'.$a2Md5;

View File

@ -61,7 +61,6 @@ abstract class AbstractOperation implements OperationInterface
$this->source = $source;
$this->target = $target;
$this->result = new MessageCatalogue($source->getLocale());
$this->domains = null;
$this->messages = array();
}