summaryrefslogtreecommitdiff
path: root/lib/phpqrcode/qrsplit.php
diff options
context:
space:
mode:
authorRasmus Lerdorf <[email protected]>2013-05-07 00:35:10 -0700
committerRasmus Lerdorf <[email protected]>2013-05-07 00:35:10 -0700
commit6f7798b6434f5ef6073447998c436901b507e3df (patch)
tree0dfe18b247ee81f7dbd2f4df37631dcd040edef8 /lib/phpqrcode/qrsplit.php
parent2c967d60237c5890549b9c9fa680ee7adec10e6a (diff)
Fixing bugs found by static analysis
Diffstat (limited to 'lib/phpqrcode/qrsplit.php')
-rw-r--r--lib/phpqrcode/qrsplit.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/phpqrcode/qrsplit.php b/lib/phpqrcode/qrsplit.php
index d75b82737..1f9f65c3b 100644
--- a/lib/phpqrcode/qrsplit.php
+++ b/lib/phpqrcode/qrsplit.php
@@ -186,7 +186,7 @@
if($ret < 0)
return -1;
- return $run;
+ return $ret;
}
//----------------------------------------------------------------------
@@ -258,7 +258,7 @@
case QR_MODE_NUM: $length = $this->eatNum(); break;
case QR_MODE_AN: $length = $this->eatAn(); break;
case QR_MODE_KANJI:
- if ($hint == QR_MODE_KANJI)
+ if ($this->modeHint == QR_MODE_KANJI)
$length = $this->eatKanji();
else $length = $this->eat8();
break;
@@ -280,7 +280,7 @@
$p = 0;
while ($p<$stringLen) {
- $mode = self::identifyMode(substr($this->dataStr, $p), $this->modeHint);
+ $mode = self::identifyMode(substr($this->dataStr, $p));
if($mode == QR_MODE_KANJI) {
$p += 2;
} else {
@@ -308,4 +308,4 @@
return $split->splitString();
}
- } \ No newline at end of file
+ }