summaryrefslogtreecommitdiff
path: root/includes/ZhClient.php
diff options
context:
space:
mode:
authorPierre Schmitz <pierre@archlinux.de>2013-12-08 09:55:49 +0100
committerPierre Schmitz <pierre@archlinux.de>2013-12-08 09:55:49 +0100
commit4ac9fa081a7c045f6a9f1cfc529d82423f485b2e (patch)
treeaf68743f2f4a47d13f2b0eb05f5c4aaf86d8ea37 /includes/ZhClient.php
parentaf4da56f1ad4d3ef7b06557bae365da2ea27a897 (diff)
Update to MediaWiki 1.22.0
Diffstat (limited to 'includes/ZhClient.php')
-rw-r--r--includes/ZhClient.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/includes/ZhClient.php b/includes/ZhClient.php
index fd03ec45..c5955aec 100644
--- a/includes/ZhClient.php
+++ b/includes/ZhClient.php
@@ -81,14 +81,14 @@ class ZhClient {
$result = fgets( $this->mFP, 1024 );
list( $status, $len ) = explode( ' ', $result );
- if( $status == 'ERROR' ) {
+ if ( $status == 'ERROR' ) {
// $len is actually the error code...
print "zhdaemon error $len<br />\n";
return false;
}
$bytesread = 0;
$data = '';
- while( !feof( $this->mFP ) && $bytesread < $len ) {
+ while ( !feof( $this->mFP ) && $bytesread < $len ) {
$str = fread( $this->mFP, $len - $bytesread );
$bytesread += strlen( $str );
$data .= $str;
@@ -131,7 +131,7 @@ class ZhClient {
$info = explode( ';', $infoline );
$ret = array();
$i = 0;
- foreach( $info as $variant ) {
+ foreach ( $info as $variant ) {
list( $code, $len ) = explode( ' ', $variant );
$ret[strtolower( $code )] = substr( $data, $i, $len );
$i += $len;