Index: export.php
===================================================================
--- export.php	(revision 20165)
+++ export.php	(working copy)
@@ -233,12 +233,15 @@
 	 * Output list of authors with posts
 	 *
 	 * @since 3.1.0
+	 *
+	 * @param array $post_ids Array of post IDs to include in the query
 	 */
-	function wxr_authors_list() {
+	function wxr_authors_list( $post_ids ) {
 		global $wpdb;
 
 		$authors = array();
-		$results = $wpdb->get_results( "SELECT DISTINCT post_author FROM $wpdb->posts" );
+		$where = 'WHERE ID IN (' . join( ',', $post_ids ) . ')';
+		$results = $wpdb->get_results( "SELECT DISTINCT post_author FROM $wpdb->posts $where" );
 		foreach ( (array) $results as $result )
 			$authors[] = get_userdata( $result->post_author );
 
@@ -337,7 +340,7 @@
 	<wp:base_site_url><?php echo wxr_site_url(); ?></wp:base_site_url>
 	<wp:base_blog_url><?php bloginfo_rss( 'url' ); ?></wp:base_blog_url>
 
-<?php wxr_authors_list(); ?>
+<?php wxr_authors_list( $post_ids ); ?>
 
 <?php foreach ( $cats as $c ) : ?>
 	<wp:category><wp:term_id><?php echo $c->term_id ?></wp:term_id><wp:category_nicename><?php echo $c->slug; ?></wp:category_nicename><wp:category_parent><?php echo $c->parent ? $cats[$c->parent]->slug : ''; ?></wp:category_parent><?php wxr_cat_name( $c ); ?><?php wxr_category_description( $c ); ?></wp:category>
