After a lot of digging I found what is causing the bug (more Fields version 2.0.5.2). I'm not sure what the best way to fix it would be since any change might break the way the plugin is supposed to work. But for the developers-- this is what's causing the bug.
In the file more-fields-rewrite-object.php there is a line
add_filter('posts_join', array(&$this, 'query_join'));
that adds a filter called query_join.
function query_join( $join ) {
global $wpdb, $wp_query;
if (!is_callable(array($wp_query, 'get'))) return false;
if ($key = $wp_query->get('mf_key') || $type = esc_attr($_GET['type'])) {
$join .= " LEFT JOIN $wpdb->postmeta as meta ON $wpdb->posts.ID = meta.post_id";
}
return $join;
}
This adds a LEFT JOIN to the normal $wp_query request parameter. This causes each image to show up 3 times in a normal $wp_query.
Then in the media library iframe the image links are paginated with the function:
$page_links = paginate_links( array(
'base' => add_query_arg( 'paged', '%#%' ),
'format' => '',
'prev_text' => __('«'),
'next_text' => __('»'),
'total' => ceil($wp_query->found_posts / 10),
'current' => $_GET['paged']
));
My media library should show 18 images split up onto 2 pages but since $wp_query->found_posts is 54 they're split up onto six pages with 4 images on each page.
=====
As a temporary fix I'm going to comment out line 16 in more-fields-rewrite-object.php
//add_filter('posts_join', array(&$this, 'query_join'));