Index: wp-admin/includes/update-core.php
===================================================================
--- wp-admin/includes/update-core.php	(revision 23246)
+++ wp-admin/includes/update-core.php	(working copy)
@@ -728,6 +728,13 @@
 		} //end foreach
 	}
 
+	// 3.5 -> 3.5+ - an empty twentytwelve directory was created upon upgrade to 3.5 for some users, preventing installation of Twenty Twelve.
+	if ( '3.5' == $old_wp_version ) {
+		if ( is_dir( WP_CONTENT_DIR . '/themes/twentytwelve' ) && ! file_exists( WP_CONTENT_DIR . '/themes/twentytwelve/style.css' )  ) {
+			$wp_filesystem->delete( $wp_filesystem->wp_themes_dir() . 'twentytwelve/', true );
+		}
+	}
+
 	// Handle $result error from the above blocks
 	if ( is_wp_error($result) ) {
 		$wp_filesystem->delete($maintenance_file);
