[wp-trac] [WordPress Trac] #17459: wp_insert_post doesn't catch query failure

WordPress Trac wp-trac at lists.automattic.com
Mon May 16 20:09:43 UTC 2011


#17459: wp_insert_post doesn't catch query failure
--------------------------+------------------------------
 Reporter:  lonnylot      |       Owner:
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Query         |     Version:
 Severity:  normal        |  Resolution:
 Keywords:                |
--------------------------+------------------------------
Changes (by nacin):

 * status:  closed => reopened
 * resolution:  invalid =>
 * milestone:   => Awaiting Review


Comment:

 $wpdb->insert() can return false, but it can also return
 mysql_affected_rows(), which on failure is -1.

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


More information about the wp-trac mailing list