summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorterox <david@terox.net>2013-03-22 14:17:08 +0100
committerterox <david@terox.net>2013-03-22 14:17:08 +0100
commited4e8aac02b44bfcb28058a255a6c3347532ecb5 (patch)
tree78d885fb6f5ef7f2bed58bb09afb0b4c98f78533
parentd028802c7d2cc00c485c0eed061947e238a12714 (diff)
downloadphp-smpp-ed4e8aac02b44bfcb28058a255a6c3347532ecb5.zip
php-smpp-ed4e8aac02b44bfcb28058a255a6c3347532ecb5.tar.gz
php-smpp-ed4e8aac02b44bfcb28058a255a6c3347532ecb5.tar.bz2
Added to regex a white space in "stat" part for some gateways
-rw-r--r--smppclient.class.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/smppclient.class.php b/smppclient.class.php
index 8a01a42..c21df0e 100644
--- a/smppclient.class.php
+++ b/smppclient.class.php
@@ -1061,7 +1061,7 @@ class SmppDeliveryReceipt extends SmppSms
*/
public function parseDeliveryReceipt()
{
- $numMatches = preg_match('/^id:([^ ]+) sub:(\d{1,3}) dlvrd:(\d{3}) submit date:(\d{10,12}) done date:(\d{10,12}) stat:([A-Z]{7}) err:(\d{2,3}) text:(.*)$/si', $this->message, $matches);
+ $numMatches = preg_match('/^id:([^ ]+) sub:(\d{1,3}) dlvrd:(\d{3}) submit date:(\d{10,12}) done date:(\d{10,12}) stat:([A-Z ]{7}) err:(\d{2,3}) text:(.*)$/si', $this->message, $matches);
if ($numMatches == 0) {
throw new InvalidArgumentException('Could not parse delivery receipt: '.$this->message."\n".bin2hex($this->body));
}