Index: wp-admin/includes/media.php
===================================================================
--- wp-admin/includes/media.php	(revision 7890)
+++ wp-admin/includes/media.php	(working copy)
@@ -586,7 +586,7 @@
 		if ( $post && $post->post_type == 'attachment' )
 			$attachments = array($post->ID => $post);
 		else
-			$attachments = get_children("post_parent=$post_id&post_type=attachment&orderby=menu_order ASC, ID&order=DESC");
+			$attachments = get_children( array( 'post_parent' => $post_id, 'post_type' => 'attachment', 'orderby' => 'menu_order ASC, ID', 'order' => 'DESC') );
 	} else {
 		if ( is_array($GLOBALS['wp_the_query']->posts) )
 			foreach ( $GLOBALS['wp_the_query']->posts as $attachment )
Index: wp-includes/media.php
===================================================================
--- wp-includes/media.php	(revision 7890)
+++ wp-includes/media.php	(working copy)
@@ -359,7 +359,7 @@
 	), $attr));
 
 	$id = intval($id);
-	$attachments = get_children("post_parent=$id&post_type=attachment&post_mime_type=image&orderby={$orderby}");
+	$attachments = get_children( array('post_parent'=> $id, 'post_type' => 'attachment', 'post_mime_type' => 'image', 'orderby' => $orderby) );
 
 	if ( empty($attachments) )
 		return '';
@@ -433,7 +433,7 @@
 function adjacent_image_link($prev = true) {
 	global $post;
 	$post = get_post($post);
-	$attachments = array_values(get_children("post_parent=$post->post_parent&post_type=attachment&post_mime_type=image&orderby=menu_order ASC, ID ASC"));
+	$attachments = array_values( get_children( array('post_parent' => $post->post_parent, 'post_type' => 'attachment', 'post_mime_type' => 'image', 'orderby' => 'menu_order ASC, ID ASC') ) );
 
 	foreach ( $attachments as $k => $attachment )
 		if ( $attachment->ID == $post->ID )
Index: wp-includes/post.php
===================================================================
--- wp-includes/post.php	(revision 7890)
+++ wp-includes/post.php	(working copy)
@@ -70,14 +70,14 @@
 function &get_children($args = '', $output = OBJECT) {
 	if ( empty( $args ) ) {
 		if ( isset( $GLOBALS['post'] ) ) {
-			$args = 'post_parent=' . (int) $GLOBALS['post']->post_parent;
+			$args = array('post_parent' => (int) $GLOBALS['post']->post_parent );
 		} else {
 			return false;
 		}
 	} elseif ( is_object( $args ) ) {
-		$args = 'post_parent=' . (int) $args->post_parent;
+		$args = array('post_parent' => (int) $args->post_parent );
 	} elseif ( is_numeric( $args ) ) {
-		$args = 'post_parent=' . (int) $args;
+		$args = array('post_parent' => (int) $args);
 	}
 
 	$defaults = array(