HHVM will throw a fatal error when passing integer and other non-string
values to mysqli::real_escape_string. A bug has been filed against
hhvm as https://github.com/facebook/hhvm/issues/1782.
Change-Id: I80eccbe8d872e74b8efc9b8c8f37ebce756bdcee
* @return string
*/
protected function mysqlRealEscapeString( $s ) {
* @return string
*/
protected function mysqlRealEscapeString( $s ) {
+ if ( is_integer( $s ) ) {
+ // HHVM fatals passing numbers to real_escape_string
+ $s = (string) $s;
+ }
return $this->mConn->real_escape_string( $s );
}
return $this->mConn->real_escape_string( $s );
}