[wp-trac] [WordPress Trac] #13195: mysql_real_escape_string() gives warning when non-string passed in

WordPress Trac wp-trac at lists.automattic.com
Fri Apr 30 22:50:55 UTC 2010


#13195: mysql_real_escape_string() gives warning when non-string passed in
------------------------------------------------+---------------------------
 Reporter:  MrWiblog                            |        Owner:          
     Type:  defect (bug)                        |       Status:  reopened
 Priority:  normal                              |    Milestone:  3.0     
Component:  Validation                          |      Version:  3.0     
 Severity:  normal                              |   Resolution:          
 Keywords:  wp-db.php mysql_real_escape_string  |  
------------------------------------------------+---------------------------
Changes (by nacin):

  * status:  closed => reopened
  * resolution:  invalid =>


Comment:

 It should not be receiving WP_Error objects.

 This is indicative of a bug. Think you can track down where the WP_Error
 is coming from? As a start, you could do something like:
 {{{
 if ( is_wp_error( $string ) ) {
    var_dump( debug_backtrace() );
    die();
 }
 }}}

 Prior to the mysql_real_escape_string() call.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/13195#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list