Index: wp-includes/default-widgets.php
===================================================================
--- wp-includes/default-widgets.php	(revision 13111)
+++ wp-includes/default-widgets.php	(working copy)
@@ -634,7 +634,7 @@
 			$number = 15;
 
 		if ( !$comments = wp_cache_get( 'recent_comments', 'widget' ) ) {
-			$comments = $wpdb->get_results("SELECT $wpdb->comments.* FROM $wpdb->comments JOIN $wpdb->posts ON $wpdb->posts.ID = $wpdb->comments.comment_post_ID WHERE comment_approved = '1' AND post_status = 'publish' ORDER BY comment_date_gmt DESC LIMIT 15");
+			$comments = $wpdb->get_results("SELECT c.* FROM $wpdb->comments c JOIN $wpdb->posts p ON p.ID = c.comment_post_ID LEFT JOIN $wpdb->posts a ON a.ID = p.post_parent WHERE c.comment_approved = '1' AND ( p.post_status = 'publish' OR ( p.post_type = 'attachment' AND a .post_status = 'publish' )) ORDER BY comment_date_gmt DESC LIMIT 15");
 			wp_cache_add( 'recent_comments', $comments, 'widget' );
 		}
 
