Index: functions.php
--- functions.php Base (BASE)
+++ functions.php Locally Modified (Based On LOCAL)
@@ -2664,9 +2664,7 @@
  * @param string|array $args Optional arguements to control behaviour.
  */
 function wp_die( $message, $title = '', $args = array() ) {
-	if ( defined( 'DOING_AJAX' ) && DOING_AJAX )
-		die('-1');
-
+   die;
 	if ( function_exists( 'apply_filters' ) ) {
 		$function = apply_filters( 'wp_die_handler', '_default_wp_die_handler');
 	} else {
@@ -2676,6 +2674,10 @@
 	call_user_func( $function, $message, $title, $args );
 }
 
+function _ajax_die_handler_filter() { 
+    return '_ajax_wp_die_handler'; 
+}
+
 /**
  * Kill WordPress execution and display HTML message with error message.
  *
@@ -2769,6 +2771,37 @@
 }
 
 /**
+ * Kill WordPress execution and send AJAX response with error message.
+ *
+ * This is AJAX-version of the default handler for wp_die
+ *
+ * @since 3.0.0
+ * @access private
+ *
+ * @param string $message Error message.
+ * @param string $title Error title.
+ * @param string|array $args Optional arguements to control behaviour.
+ */
+function _ajax_wp_die_handler( $message, $title = '', $args = array() ) {
+	$defaults = array( 'response' => 500 );
+	$r = wp_parse_args($args, $defaults);
+	$have_gettext = function_exists('__');        
+	if ( !function_exists( 'did_action' ) || !did_action( 'admin_head' ) ) :
+	if ( !headers_sent() ) {
+		status_header( $r['response'] );
+		nocache_headers();
+		header( 'Content-Type: text/html; charset=utf-8' );
+	}        
+        $resp   =   new WP_Ajax_Response( array(
+			'what' => 'autosave',
+			'id' => $message,
+			'data' => $message
+		) );
+	$resp->send();
+	die();
+}
+
+/**
  * Retrieve the WordPress home page URL.
  *
  * If the constant named 'WP_HOME' exists, then it willl be used and returned by
