Index: class-wp-xmlrpc-server.php
===================================================================
--- class-wp-xmlrpc-server.php	(revision 17287)
+++ class-wp-xmlrpc-server.php	(working copy)
@@ -2303,7 +2303,15 @@
 				}
 			}
 		}
+		if ( isset( $content_struct['wp_category_ids'] ) ) {
+			$catids = array_map( 'intval', $content_struct['wp_category_ids'] );
+			logIO('O', 'Post cat ids: ' . var_export($catids, true));
 
+			if ( is_array($catids) ) {
+				$post_category = array_merge( $post_category, array_diff( $catids, $post_category ) );
+			}
+		}
+
 		// We've got all the data -- post it:
 		$postdata = compact('post_author', 'post_date', 'post_date_gmt', 'post_content', 'post_title', 'post_category', 'post_status', 'post_excerpt', 'comment_status', 'ping_status', 'to_ping', 'post_type', 'post_name', 'post_password', 'post_parent', 'menu_order', 'tags_input', 'page_template');
 
@@ -2567,7 +2575,15 @@
 				}
 			}
 		}
+		if ( isset( $content_struct['wp_category_ids'] ) ) {
+			$catids = array_map( 'intval', $content_struct['wp_category_ids'] );
+			logIO('O', 'Post cat ids: ' . var_export($catids, true));
 
+			if ( is_array($catids) ) {
+				$post_category = array_merge( $post_category, array_diff( $catids, $post_category ) );
+			}
+		}
+
 		$post_excerpt = isset( $content_struct['mt_excerpt'] ) ? $content_struct['mt_excerpt'] : null;
 		$post_more = isset( $content_struct['mt_text_more'] ) ? $content_struct['mt_text_more'] : null;
 
@@ -2755,6 +2771,7 @@
 				// commented out because no other tool seems to use this
 				//	      'content' => $entry['post_content'],
 				'categories' => $categories,
+				'wp_category_ids' => array_map( 'intval', $catids ),
 				'mt_excerpt' => $postdata['post_excerpt'],
 				'mt_text_more' => $post['extended'],
 				'mt_allow_comments' => $allow_comments,
@@ -2865,6 +2882,7 @@
 				// commented out because no other tool seems to use this
 				// 'content' => $entry['post_content'],
 				'categories' => $categories,
+				'wp_category_ids' => array_map( 'intval', $catids ),
 				'mt_excerpt' => $entry['post_excerpt'],
 				'mt_text_more' => $post['extended'],
 				'mt_allow_comments' => $allow_comments,
