Permalink
Browse files

Match SP as per rfc2821

  • Loading branch information...
1 parent c182407 commit 0ae225615c5101c66d3e51005a9d7270b47d7a20 @ndm2 ndm2 committed Mar 15, 2014
@@ -133,7 +133,7 @@ public function config($config = null) {
protected function _bufferResponseLines(array $responseLines) {
$response = array();
foreach ($responseLines as $responseLine) {
- if (preg_match('/^(\d{3})(?:[\s\-]+(.*))?$/', $responseLine, $match)) {
+ if (preg_match('/^(\d{3})(?:[ -]+(.*))?$/', $responseLine, $match)) {
$response[] = array(
'code' => $match[1],
'message' => isset($match[2]) ? $match[2] : null
@@ -431,6 +431,7 @@ public function testGetLastResponse() {
public function testBufferResponseLines() {
$reponseLines = array(
'123',
+ "456\tFOO",
'FOOBAR',
'250-PIPELINING',
'250-ENHANCEDSTATUSCODES',

0 comments on commit 0ae2256

Please sign in to comment.