# This patch file was generated by NetBeans IDE
# Following Index: paths are relative to: C:\xampp\htdocs\wordtrunk\wp-includes
# This patch can be applied using context Tools: Patch action on respective folder.
# It uses platform neutral UTF-8 encoding and \n newlines.
# Above lines and this line are ignored by the patching process.
Index: class-wp-xmlrpc-server.php
--- class-wp-xmlrpc-server.php Base (BASE)
+++ class-wp-xmlrpc-server.php Locally Modified (Based On LOCAL)
@@ -64,6 +64,7 @@
 			'wp.getMediaItem'		=> 'this:wp_getMediaItem',
 			'wp.getMediaLibrary'	=> 'this:wp_getMediaLibrary',
 			'wp.getPostFormats'     => 'this:wp_getPostFormats',
+			'wp.deleteUser'			=> 'this:wp_deleteUser',
 
 			// Blogger API
 			'blogger.getUsersBlogs' => 'this:blogger_getUsersBlogs',
@@ -1702,6 +1703,57 @@
 		return $formats;
 	}
 
+	/**
+	 * Delete a user
+	 *
+	 * @uses wp_delete_user()
+	 * @param array $args Method parameters. Contains:
+	 *  - int     $blog_id
+	 *  - string  $username
+	 *  - string  $password
+	 *  - int     $user_id
+	 * @return True when user is deleted.
+	 */
+        function wp_deleteUser($args) {
+                $this->escape($args);
+
+                $blog_id = (int) $args[0];
+                $username = $args[1];
+                $password = $args[2];
+                $user_id = (int) $args[3];
+
+                if (!$user = $this->login($username, $password))
+                        return $this->error;
+
+                do_action('xmlrpc_call', 'wp.deleteUser');
+
+                if (!current_user_can('delete_users'))
+                        return new IXR_Error(401, __('You are not allowed to delete users.'));
+
+                if (!get_userdata($user_id))
+                        return new IXR_Error(404, __('Invalid user ID.'));
+
+                if ($user->ID == $user_id)
+                        return new IXR_Error(401, __('You cannot delete yourself.'));
+
+                if (isset($args[4])) {
+                        $reassign_id = (int) $args[4];
+                        if (!get_userdata($user_id))
+                                return new IXR_Error(404, __('Invalid reassign user ID.'));
+                        if($reassign_id == $user_id)
+                                return new IXR_Error(404, __('Cannot reassign for a deleting user.'));
+                } else {
+                        $reassign_id = 'novalue';
+                }
+
+                $result = wp_delete_user($user_id, $reassign_id);
+
+                if (!$result)
+                        return new IXR_Error(500, __('Cannot delete user.'));
+
+                return true;
+        }
+
 	/* Blogger API functions.
 	 * specs on http://plant.blogger.com/api and http://groups.yahoo.com/group/bloggerDev/
 	 */
