r89792 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r89791‎ | r89792 | r89793 >
Date:19:57, 9 June 2011
Author:platonides
Status:ok
Tags:
Comment:
If this was ever passed an empty string it would spit "PHP Notice: Uninitialized string offset: 0..."
Modified paths:
  • /trunk/phase3/includes/db/DatabaseMysql.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/db/DatabaseMysql.php
@@ -330,7 +330,7 @@
331331 }
332332
333333 public function isQuotedIdentifier( $name ) {
334 - return $name[0] == '`' && substr( $name, -1, 1 ) == '`';
 334+ return strlen($name) && $name[0] == '`' && substr( $name, -1, 1 ) == '`';
335335 }
336336
337337 function ping() {

Status & tagging log