Index: wp-includes/post.php
===================================================================
--- wp-includes/post.php	(revision 23387)
+++ wp-includes/post.php	(working copy)
@@ -3906,6 +3906,7 @@
  * @uses $user_ID
  * @uses do_action() Calls 'edit_attachment' on $post_ID if this is an update.
  * @uses do_action() Calls 'add_attachment' on $post_ID if this is not an update.
+ * @uses apply_filters() Calls 'wp_insert_attachment_data' passing $data, $object prior to database update or insert.
  *
  * @param string|array $object Arguments to override defaults.
  * @param string $file Optional filename.
@@ -4009,6 +4010,8 @@
 	$data = compact( array( 'post_author', 'post_date', 'post_date_gmt', 'post_content', 'post_content_filtered', 'post_title', 'post_excerpt', 'post_status', 'post_type', 'comment_status', 'ping_status', 'post_password', 'post_name', 'to_ping', 'pinged', 'post_modified', 'post_modified_gmt', 'post_parent', 'menu_order', 'post_mime_type', 'guid' ) );
 	$data = stripslashes_deep( $data );
 
+	$data = apply_filters('wp_insert_attachment_data', $data, $object);
+
 	if ( $update ) {
 		$wpdb->update( $wpdb->posts, $data, array( 'ID' => $post_ID ) );
 	} else {
