<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[19935] trunk: Deprecate ancient &quot;debugging&quot; tools.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg > ul, #logmsg > ol { margin-left: 0; margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://core.trac.wordpress.org/changeset/19935">19935</a></dd>
<dt>Author</dt> <dd>nacin</dd>
<dt>Date</dt> <dd>2012-02-17 00:02:42 +0000 (Fri, 17 Feb 2012)</dd>
</dl>

<h3>Log Message</h3>
<pre>Deprecate ancient &quot;debugging&quot; tools.
 * logIO() and the global $xmlrpc_logging in XML-RPC.
 * log_app() and the global $app_logging in APP.
 * debug_fwrite(), debug_fopen(), debug_fclose(), and $debug.
see <a href="http://core.trac.wordpress.org/ticket/20051">#20051</a>.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpadminincludesupgradephp">trunk/wp-admin/includes/upgrade.php</a></li>
<li><a href="#trunkwpadmininstallhelperphp">trunk/wp-admin/install-helper.php</a></li>
<li><a href="#trunkwpappphp">trunk/wp-app.php</a></li>
<li><a href="#trunkwpincludesclasswpxmlrpcserverphp">trunk/wp-includes/class-wp-xmlrpc-server.php</a></li>
<li><a href="#trunkwpincludesclasswpphp">trunk/wp-includes/class-wp.php</a></li>
<li><a href="#trunkwpincludesdeprecatedphp">trunk/wp-includes/deprecated.php</a></li>
<li><a href="#trunkwpincludesfunctionsphp">trunk/wp-includes/functions.php</a></li>
<li><a href="#trunkxmlrpcphp">trunk/xmlrpc.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpadminincludesupgradephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/includes/upgrade.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/includes/upgrade.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-admin/includes/upgrade.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -1359,9 +1359,8 @@
</span><span class="cx">  **           false on error
</span><span class="cx">  */
</span><span class="cx"> function maybe_add_column($table_name, $column_name, $create_ddl) {
</span><del>-        global $wpdb, $debug;
</del><ins>+        global $wpdb;
</ins><span class="cx">         foreach ($wpdb-&gt;get_col(&quot;DESC $table_name&quot;, 0) as $column ) {
</span><del>-                if ($debug) echo(&quot;checking $column == $column_name&lt;br /&gt;&quot;);
</del><span class="cx">                 if ($column == $column_name) {
</span><span class="cx">                         return true;
</span><span class="cx">                 }
</span></span></pre></div>
<a id="trunkwpadmininstallhelperphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/install-helper.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/install-helper.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-admin/install-helper.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -10,9 +10,6 @@
</span><span class="cx">  * needing to use these functions a lot, you might experience time outs. If you
</span><span class="cx">  * do, then it is advised to just write the SQL code yourself.
</span><span class="cx">  *
</span><del>- * You can turn debugging on, by setting $debug to 1 after you include this
- * file.
- *
</del><span class="cx">  * &lt;code&gt;
</span><span class="cx">  * check_column('wp_links', 'link_description', 'mediumtext');
</span><span class="cx">  * if (check_column($wpdb-&gt;comments, 'comment_author', 'tinytext'))
</span><span class="lines">@@ -41,15 +38,6 @@
</span><span class="cx"> /** Load WordPress Bootstrap */
</span><span class="cx"> require_once(dirname(dirname(__FILE__)).'/wp-load.php');
</span><span class="cx"> 
</span><del>-/**
- * Turn debugging on or off.
- * @global bool|int $debug
- * @name $debug
- * @var bool|int
- * @since 1.0.0
- */
-$debug = 0;
-
</del><span class="cx"> if ( ! function_exists('maybe_create_table') ) :
</span><span class="cx"> /**
</span><span class="cx">  * Create database table, if it doesn't already exist.
</span><span class="lines">@@ -90,7 +78,6 @@
</span><span class="cx">  * @package WordPress
</span><span class="cx">  * @subpackage Plugin
</span><span class="cx">  * @uses $wpdb
</span><del>- * @uses $debug
</del><span class="cx">  *
</span><span class="cx">  * @param string $table_name Database table name
</span><span class="cx">  * @param string $column_name Table column name
</span><span class="lines">@@ -98,9 +85,8 @@
</span><span class="cx">  * @return bool False on failure. True, if already exists or was successful.
</span><span class="cx">  */
</span><span class="cx"> function maybe_add_column($table_name, $column_name, $create_ddl) {
</span><del>-        global $wpdb, $debug;
</del><ins>+        global $wpdb;
</ins><span class="cx">         foreach ($wpdb-&gt;get_col(&quot;DESC $table_name&quot;,0) as $column ) {
</span><del>-                if ($debug) echo(&quot;checking $column == $column_name&lt;br /&gt;&quot;);
</del><span class="cx"> 
</span><span class="cx">                 if ($column == $column_name) {
</span><span class="cx">                         return true;
</span><span class="lines">@@ -179,16 +165,14 @@
</span><span class="cx">  * @return bool True, if matches. False, if not matching.
</span><span class="cx">  */
</span><span class="cx"> function check_column($table_name, $col_name, $col_type, $is_null = null, $key = null, $default = null, $extra = null) {
</span><del>-        global $wpdb, $debug;
</del><ins>+        global $wpdb;
</ins><span class="cx">         $diffs = 0;
</span><span class="cx">         $results = $wpdb-&gt;get_results(&quot;DESC $table_name&quot;);
</span><span class="cx"> 
</span><span class="cx">         foreach ($results as $row ) {
</span><del>-                if ($debug &gt; 1) print_r($row);
</del><span class="cx"> 
</span><span class="cx">                 if ($row-&gt;Field == $col_name) {
</span><span class="cx">                         // got our column, check the params
</span><del>-                        if ($debug) echo (&quot;checking $row-&gt;Type against $col_type\n&quot;);
</del><span class="cx">                         if (($col_type != null) &amp;&amp; ($row-&gt;Type != $col_type)) {
</span><span class="cx">                                 ++$diffs;
</span><span class="cx">                         }
</span><span class="lines">@@ -205,7 +189,6 @@
</span><span class="cx">                                 ++$diffs;
</span><span class="cx">                         }
</span><span class="cx">                         if ($diffs &gt; 0) {
</span><del>-                                if ($debug) echo (&quot;diffs = $diffs returning false\n&quot;);
</del><span class="cx">                                 return false;
</span><span class="cx">                         }
</span><span class="cx">                         return true;
</span></span></pre></div>
<a id="trunkwpappphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-app.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-app.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-app.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -24,14 +24,6 @@
</span><span class="cx"> $_SERVER['PATH_INFO'] = preg_replace( '/.*\/wp-app\.php/', '', $_SERVER['REQUEST_URI'] );
</span><span class="cx"> 
</span><span class="cx"> /**
</span><del>- * Whether to enable Atom Publishing Protocol Logging.
- *
- * @name app_logging
- * @var int|bool
- */
-$app_logging = 0;
-
-/**
</del><span class="cx">  * Whether to always authenticate user. Permanently set to true.
</span><span class="cx">  *
</span><span class="cx">  * @name always_authenticate
</span><span class="lines">@@ -44,21 +36,17 @@
</span><span class="cx">  * Writes logging info to a file.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.2.0
</span><del>- * @uses $app_logging
- * @package WordPress
- * @subpackage Logging
</del><ins>+ * @deprecated 3.4.0
+ * @deprecated Use error_log()
+ * @link http://www.php.net/manual/en/function.error-log.php
</ins><span class="cx">  *
</span><span class="cx">  * @param string $label Type of logging
</span><span class="cx">  * @param string $msg Information describing logging reason.
</span><span class="cx">  */
</span><del>-function log_app($label,$msg) {
-        global $app_logging;
-        if ($app_logging) {
-                $fp = fopen( 'wp-app.log', 'a+');
-                $date = gmdate( 'Y-m-d H:i:s' );
-                fwrite($fp, &quot;\n\n$date - $label\n$msg\n&quot;);
-                fclose($fp);
-        }
</del><ins>+function log_app( $label, $msg ) {
+        _deprecated_function( __FUNCTION__, '3.4', 'error_log()' );
+        if ( ! empty( $GLOBALS['app_logging'] ) )
+                error_log( $label . ' - ' . $message );
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> /**
</span><span class="lines">@@ -268,8 +256,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $method = $_SERVER['REQUEST_METHOD'];
</span><span class="cx"> 
</span><del>-                log_app('REQUEST',&quot;$method $path\n================&quot;);
-
</del><span class="cx">                 $this-&gt;process_conditionals();
</span><span class="cx">                 //$this-&gt;process_conditionals();
</span><span class="cx"> 
</span><span class="lines">@@ -319,8 +305,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function get_service() {
</span><del>-                log_app('function','get_service()');
-
</del><span class="cx">                 if ( !current_user_can( 'edit_posts' ) )
</span><span class="cx">                         $this-&gt;auth_required( __( 'Sorry, you do not have the right to access this site.' ) );
</span><span class="cx"> 
</span><span class="lines">@@ -360,8 +344,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function get_categories_xml() {
</span><del>-                log_app('function','get_categories_xml()');
-
</del><span class="cx">                 if ( !current_user_can( 'edit_posts' ) )
</span><span class="cx">                         $this-&gt;auth_required( __( 'Sorry, you do not have the right to access this site.' ) );
</span><span class="cx"> 
</span><span class="lines">@@ -397,8 +379,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $entry = array_pop($parser-&gt;feed-&gt;entries);
</span><span class="cx"> 
</span><del>-                log_app('Received entry:', print_r($entry,true));
-
</del><span class="cx">                 $catnames = array();
</span><span class="cx">                 if ( !empty( $entry-&gt;categories ) ) {
</span><span class="cx">                         foreach ( $entry-&gt;categories as $cat ) {
</span><span class="lines">@@ -451,7 +431,6 @@
</span><span class="cx">                 $post_data = compact('blog_ID', 'post_author', 'post_date', 'post_date_gmt', 'post_content', 'post_title', 'post_category', 'post_status', 'post_excerpt', 'post_name');
</span><span class="cx"> 
</span><span class="cx">                 $this-&gt;escape($post_data);
</span><del>-                log_app('Inserting Post. Data:', print_r($post_data,true));
</del><span class="cx"> 
</span><span class="cx">                 $postID = wp_insert_post($post_data);
</span><span class="cx">                 if ( is_wp_error( $postID ) )
</span><span class="lines">@@ -470,7 +449,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $output = $this-&gt;get_entry($postID);
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;create_post($postID)&quot;);
</del><span class="cx">                 $this-&gt;created($postID, $output);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -489,7 +467,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $this-&gt;set_current_entry($postID);
</span><span class="cx">                 $output = $this-&gt;get_entry($postID);
</span><del>-                log_app('function',&quot;get_post($postID)&quot;);
</del><span class="cx">                 $this-&gt;output($output);
</span><span class="cx"> 
</span><span class="cx">         }
</span><span class="lines">@@ -512,8 +489,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $parsed = array_pop($parser-&gt;feed-&gt;entries);
</span><span class="cx"> 
</span><del>-                log_app('Received UPDATED entry:', print_r($parsed,true));
-
</del><span class="cx">                 // check for not found
</span><span class="cx">                 global $entry;
</span><span class="cx">                 $this-&gt;set_current_entry($postID);
</span><span class="lines">@@ -546,7 +521,6 @@
</span><span class="cx"> 
</span><span class="cx">                 do_action( 'atompub_put_post', $ID, $parsed );
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;put_post($postID)&quot;);
</del><span class="cx">                 $this-&gt;ok();
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -575,7 +549,6 @@
</span><span class="cx">                                 $this-&gt;internal_error(__('For some strange yet very annoying reason, this post could not be deleted.'));
</span><span class="cx">                         }
</span><span class="cx"> 
</span><del>-                        log_app('function',&quot;delete_post($postID)&quot;);
</del><span class="cx">                         $this-&gt;ok();
</span><span class="cx">                 }
</span><span class="cx"> 
</span><span class="lines">@@ -597,7 +570,6 @@
</span><span class="cx">                 } else {
</span><span class="cx">                         $this-&gt;set_current_entry($postID);
</span><span class="cx">                         $output = $this-&gt;get_entry($postID, 'attachment');
</span><del>-                        log_app('function',&quot;get_attachment($postID)&quot;);
</del><span class="cx">                         $this-&gt;output($output);
</span><span class="cx">                 }
</span><span class="cx">         }
</span><span class="lines">@@ -632,8 +604,6 @@
</span><span class="cx">                 $slug = sanitize_file_name( &quot;$slug.$ext&quot; );
</span><span class="cx">                 $file = wp_upload_bits( $slug, null, $bits);
</span><span class="cx"> 
</span><del>-                log_app('wp_upload_bits returns:',print_r($file,true));
-
</del><span class="cx">                 $url = $file['url'];
</span><span class="cx">                 $file = $file['file'];
</span><span class="cx"> 
</span><span class="lines">@@ -658,7 +628,6 @@
</span><span class="cx">                 $output = $this-&gt;get_entry($postID, 'attachment');
</span><span class="cx"> 
</span><span class="cx">                 $this-&gt;created($postID, $output, 'attachment');
</span><del>-                log_app('function',&quot;create_attachment($postID)&quot;);
</del><span class="cx">         }
</span><span class="cx"> 
</span><span class="cx">         /**
</span><span class="lines">@@ -703,7 +672,6 @@
</span><span class="cx">                 if ( !$result )
</span><span class="cx">                         $this-&gt;internal_error(__('For some strange yet very annoying reason, this post could not be edited.'));
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;put_attachment($postID)&quot;);
</del><span class="cx">                 $this-&gt;ok();
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -715,8 +683,6 @@
</span><span class="cx">          * @param int $postID Post ID.
</span><span class="cx">          */
</span><span class="cx">         function delete_attachment($postID) {
</span><del>-                log_app('function',&quot;delete_attachment($postID). File '$location' deleted.&quot;);
-
</del><span class="cx">                 // check for not found
</span><span class="cx">                 global $entry;
</span><span class="cx">                 $this-&gt;set_current_entry($postID);
</span><span class="lines">@@ -739,7 +705,6 @@
</span><span class="cx">                 if ( !$result )
</span><span class="cx">                         $this-&gt;internal_error(__('For some strange yet very annoying reason, this post could not be deleted.'));
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;delete_attachment($postID). File '$location' deleted.&quot;);
</del><span class="cx">                 $this-&gt;ok();
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -785,7 +750,6 @@
</span><span class="cx">                         status_header ('404');
</span><span class="cx">                 }
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;get_file($postID)&quot;);
</del><span class="cx">                 exit;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -843,7 +807,6 @@
</span><span class="cx"> 
</span><span class="cx">                 wp_update_attachment_metadata( $postID, wp_generate_attachment_metadata( $postID, $location ) );
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;put_file($postID)&quot;);
</del><span class="cx">                 $this-&gt;ok();
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -954,7 +917,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $url = $this-&gt;app_base . $this-&gt;ENTRY_PATH . &quot;/$postID&quot;;
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;get_entry_url() = $url&quot;);
</del><span class="cx">                 return $url;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -985,7 +947,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $url = $this-&gt;app_base . $this-&gt;MEDIA_SINGLE_PATH .&quot;/file/$postID&quot;;
</span><span class="cx"> 
</span><del>-                log_app('function',&quot;get_media_url() = $url&quot;);
</del><span class="cx">                 return $url;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1009,7 +970,6 @@
</span><span class="cx">          */
</span><span class="cx">         function set_current_entry($postID) {
</span><span class="cx">                 global $entry;
</span><del>-                log_app('function',&quot;set_current_entry($postID)&quot;);
</del><span class="cx"> 
</span><span class="cx">                 if (!isset($postID)) {
</span><span class="cx">                         // $this-&gt;bad_request();
</span><span class="lines">@@ -1033,7 +993,6 @@
</span><span class="cx">          * @param string $post_type Optional, default is 'post'. Post Type.
</span><span class="cx">          */
</span><span class="cx">         function get_posts($page = 1, $post_type = 'post') {
</span><del>-                        log_app('function',&quot;get_posts($page, '$post_type')&quot;);
</del><span class="cx">                         $feed = $this-&gt;get_feed($page, $post_type);
</span><span class="cx">                         $this-&gt;output($feed);
</span><span class="cx">         }
</span><span class="lines">@@ -1047,7 +1006,6 @@
</span><span class="cx">          * @param string $post_type Optional, default is 'attachment'. Post type.
</span><span class="cx">          */
</span><span class="cx">         function get_attachments($page = 1, $post_type = 'attachment') {
</span><del>-                log_app('function',&quot;get_attachments($page, '$post_type')&quot;);
</del><span class="cx">                 $GLOBALS['post_type'] = $post_type;
</span><span class="cx">                 $feed = $this-&gt;get_feed($page, $post_type);
</span><span class="cx">                 $this-&gt;output($feed);
</span><span class="lines">@@ -1064,7 +1022,6 @@
</span><span class="cx">          */
</span><span class="cx">         function get_feed($page = 1, $post_type = 'post') {
</span><span class="cx">                 global $post, $wp, $wp_query, $posts, $wpdb, $blog_id;
</span><del>-                log_app('function',&quot;get_feed($page, '$post_type')&quot;);
</del><span class="cx">                 ob_start();
</span><span class="cx"> 
</span><span class="cx">                 $this-&gt;ENTRY_PATH = $post_type;
</span><span class="lines">@@ -1084,9 +1041,7 @@
</span><span class="cx">                 $wp_query = $GLOBALS['wp_query'];
</span><span class="cx">                 $wpdb = $GLOBALS['wpdb'];
</span><span class="cx">                 $blog_id = (int) $GLOBALS['blog_id'];
</span><del>-                log_app('function',&quot;query_posts(# &quot; . print_r($wp_query, true) . &quot;#)&quot;);
</del><span class="cx"> 
</span><del>-                log_app('function',&quot;total_count(# $wp_query-&gt;max_num_pages #)&quot;);
</del><span class="cx">                 $last_page = $wp_query-&gt;max_num_pages;
</span><span class="cx">                 $next_page = (($page + 1) &gt; $last_page) ? null : $page + 1;
</span><span class="cx">                 $prev_page = ($page - 1) &lt; 1 ? null : $page - 1;
</span><span class="lines">@@ -1131,7 +1086,6 @@
</span><span class="cx">          * @return string.
</span><span class="cx">          */
</span><span class="cx">         function get_entry($postID, $post_type = 'post') {
</span><del>-                log_app('function',&quot;get_entry($postID, '$post_type')&quot;);
</del><span class="cx">                 ob_start();
</span><span class="cx">                 switch($post_type) {
</span><span class="cx">                         case 'post':
</span><span class="lines">@@ -1147,14 +1101,12 @@
</span><span class="cx">                         while ( have_posts() ) {
</span><span class="cx">                                 the_post();
</span><span class="cx">                                 $this-&gt;echo_entry();
</span><del>-                                log_app('$post',print_r($GLOBALS['post'],true));
</del><span class="cx">                                 $entry = ob_get_contents();
</span><span class="cx">                                 break;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="cx">                 ob_end_clean();
</span><span class="cx"> 
</span><del>-                log_app('get_entry returning:',$entry);
</del><span class="cx">                 return $entry;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1205,7 +1157,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function ok() {
</span><del>-                log_app('Status','200: OK');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('200');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1217,7 +1168,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function no_content() {
</span><del>-                log_app('Status','204: No Content');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('204');
</span><span class="cx">                 echo &quot;Moved to Trash.&quot;;
</span><span class="lines">@@ -1232,7 +1182,6 @@
</span><span class="cx">          * @param string $msg Optional. Status string.
</span><span class="cx">          */
</span><span class="cx">         function internal_error($msg = 'Internal Server Error') {
</span><del>-                log_app('Status','500: Server Error');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('500');
</span><span class="cx">                 echo $msg;
</span><span class="lines">@@ -1245,7 +1194,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function bad_request() {
</span><del>-                log_app('Status','400: Bad Request');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('400');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1257,7 +1205,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function length_required() {
</span><del>-                log_app('Status','411: Length Required');
</del><span class="cx">                 header(&quot;HTTP/1.1 411 Length Required&quot;);
</span><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('411');
</span><span class="lines">@@ -1270,7 +1217,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function invalid_media() {
</span><del>-                log_app('Status','415: Unsupported Media Type');
</del><span class="cx">                 header(&quot;HTTP/1.1 415 Unsupported Media Type&quot;);
</span><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1282,7 +1228,6 @@
</span><span class="cx">          * @since 2.6.0
</span><span class="cx">          */
</span><span class="cx">         function forbidden($reason='') {
</span><del>-                log_app('Status','403: Forbidden');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('403');
</span><span class="cx">                 echo $reason;
</span><span class="lines">@@ -1295,7 +1240,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function not_found() {
</span><del>-                log_app('Status','404: Not Found');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('404');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1307,7 +1251,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function not_allowed($allow) {
</span><del>-                log_app('Status','405: Not Allowed');
</del><span class="cx">                 header('Allow: ' . join(',', $allow));
</span><span class="cx">                 status_header('405');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1319,8 +1262,6 @@
</span><span class="cx">          * @since 2.3.0
</span><span class="cx">          */
</span><span class="cx">         function redirect($url) {
</span><del>-
-                log_app('Status','302: Redirect');
</del><span class="cx">                 $escaped_url = esc_attr($url);
</span><span class="cx">                 $content = &lt;&lt;&lt;EOD
</span><span class="cx"> &lt;!DOCTYPE HTML PUBLIC &quot;-//IETF//DTD HTML 2.0//EN&quot;&gt;
</span><span class="lines">@@ -1349,7 +1290,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function client_error($msg = 'Client Error') {
</span><del>-                log_app('Status','400: Client Error');
</del><span class="cx">                 header('Content-Type: text/plain');
</span><span class="cx">                 status_header('400');
</span><span class="cx">                 exit;
</span><span class="lines">@@ -1363,7 +1303,6 @@
</span><span class="cx">          * @since 2.2.0
</span><span class="cx">          */
</span><span class="cx">         function created($post_ID, $content, $post_type = 'post') {
</span><del>-                log_app('created()::$post_ID',&quot;$post_ID, $post_type&quot;);
</del><span class="cx">                 $edit = $this-&gt;get_entry_url($post_ID);
</span><span class="cx">                 switch($post_type) {
</span><span class="cx">                         case 'post':
</span><span class="lines">@@ -1390,7 +1329,6 @@
</span><span class="cx">          * @param string $msg Status header content and HTML content.
</span><span class="cx">          */
</span><span class="cx">         function auth_required($msg) {
</span><del>-                log_app('Status','401: Auth Required');
</del><span class="cx">                 nocache_headers();
</span><span class="cx">                 header('WWW-Authenticate: Basic realm=&quot;WordPress Atom Protocol&quot;');
</span><span class="cx">                 header(&quot;HTTP/1.1 401 $msg&quot;);
</span><span class="lines">@@ -1431,7 +1369,6 @@
</span><span class="cx">                         header('Date: '. date('r'));
</span><span class="cx">                         if ($this-&gt;do_output)
</span><span class="cx">                                 echo $xml;
</span><del>-                        log_app('function', &quot;output:\n$xml&quot;);
</del><span class="cx">                         exit;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1464,8 +1401,6 @@
</span><span class="cx">          * @return bool
</span><span class="cx">          */
</span><span class="cx">         function authenticate() {
</span><del>-                log_app(&quot;authenticate()&quot;,print_r($_ENV, true));
-
</del><span class="cx">                 // if using mod_rewrite/ENV hack
</span><span class="cx">                 // http://www.besthostratings.com/articles/http-auth-php-cgi.html
</span><span class="cx">                 if (isset($_SERVER['HTTP_AUTHORIZATION'])) {
</span><span class="lines">@@ -1480,12 +1415,9 @@
</span><span class="cx"> 
</span><span class="cx">                 // If Basic Auth is working...
</span><span class="cx">                 if (isset($_SERVER['PHP_AUTH_USER']) &amp;&amp; isset($_SERVER['PHP_AUTH_PW'])) {
</span><del>-                        log_app(&quot;Basic Auth&quot;,$_SERVER['PHP_AUTH_USER']);
-
</del><span class="cx">                         $user = wp_authenticate($_SERVER['PHP_AUTH_USER'], $_SERVER['PHP_AUTH_PW']);
</span><span class="cx">                         if ( $user &amp;&amp; !is_wp_error($user) ) {
</span><span class="cx">                                 wp_set_current_user($user-&gt;ID);
</span><del>-                                log_app(&quot;authenticate()&quot;, $user-&gt;user_login);
</del><span class="cx">                                 return true;
</span><span class="cx">                         }
</span><span class="cx">                 }
</span><span class="lines">@@ -1514,7 +1446,6 @@
</span><span class="cx">                 $type = $_SERVER['CONTENT_TYPE'];
</span><span class="cx">                 list($type,$subtype) = explode('/',$type);
</span><span class="cx">                 list($subtype) = explode(&quot;;&quot;,$subtype); // strip MIME parameters
</span><del>-                log_app(&quot;get_accepted_content_type&quot;, &quot;type=$type, subtype=$subtype&quot;);
</del><span class="cx"> 
</span><span class="cx">                 foreach($types as $t) {
</span><span class="cx">                         list($acceptedType,$acceptedSubtype) = explode('/',$t);
</span></span></pre></div>
<a id="trunkwpincludesclasswpxmlrpcserverphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-wp-xmlrpc-server.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-wp-xmlrpc-server.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-includes/class-wp-xmlrpc-server.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -2700,8 +2700,6 @@
</span><span class="cx"> 
</span><span class="cx">                 $this-&gt;attach_uploads( $post_ID, $post_content );
</span><span class="cx"> 
</span><del>-                logIO('O', &quot;Posted ! ID: $post_ID&quot;);
-
</del><span class="cx">                 return $post_ID;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -3046,7 +3044,6 @@
</span><span class="cx">                 $post_category = array();
</span><span class="cx">                 if ( isset( $content_struct['categories'] ) ) {
</span><span class="cx">                         $catnames = $content_struct['categories'];
</span><del>-                        logIO('O', 'Post cats: ' . var_export($catnames,true));
</del><span class="cx"> 
</span><span class="cx">                         if ( is_array($catnames) ) {
</span><span class="cx">                                 foreach ($catnames as $cat) {
</span><span class="lines">@@ -3088,8 +3085,6 @@
</span><span class="cx">                 if ( !$post_ID )
</span><span class="cx">                         return new IXR_Error(500, __('Sorry, your entry could not be posted. Something wrong happened.'));
</span><span class="cx"> 
</span><del>-                logIO('O', &quot;Posted ! ID: $post_ID&quot;);
-
</del><span class="cx">                 return strval($post_ID);
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -3381,8 +3376,6 @@
</span><span class="cx">                 if ( isset( $content_struct['wp_post_format'] ) )
</span><span class="cx">                         wp_set_post_terms( $post_ID, array( 'post-format-' . $content_struct['wp_post_format'] ), 'post_format' );
</span><span class="cx"> 
</span><del>-                logIO('O',&quot;(MW) Edited ! ID: $post_ID&quot;);
-
</del><span class="cx">                 return true;
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -3695,15 +3688,12 @@
</span><span class="cx">                 $type = $data['type'];
</span><span class="cx">                 $bits = $data['bits'];
</span><span class="cx"> 
</span><del>-                logIO('O', '(MW) Received '.strlen($bits).' bytes');
-
</del><span class="cx">                 if ( !$user = $this-&gt;login($username, $password) )
</span><span class="cx">                         return $this-&gt;error;
</span><span class="cx"> 
</span><span class="cx">                 do_action('xmlrpc_call', 'metaWeblog.newMediaObject');
</span><span class="cx"> 
</span><span class="cx">                 if ( !current_user_can('upload_files') ) {
</span><del>-                        logIO('O', '(MW) User does not have upload_files capability');
</del><span class="cx">                         $this-&gt;error = new IXR_Error(401, __('You are not allowed to upload files to this site.'));
</span><span class="cx">                         return $this-&gt;error;
</span><span class="cx">                 }
</span><span class="lines">@@ -3732,7 +3722,6 @@
</span><span class="cx">                 $upload = wp_upload_bits($name, null, $bits);
</span><span class="cx">                 if ( ! empty($upload['error']) ) {
</span><span class="cx">                         $errorString = sprintf(__('Could not write file %1$s (%2$s)'), $name, $upload['error']);
</span><del>-                        logIO('O', '(MW) ' . $errorString);
</del><span class="cx">                         return new IXR_Error(500, $errorString);
</span><span class="cx">                 }
</span><span class="cx">                 // Construct the attachment array
</span><span class="lines">@@ -4119,8 +4108,6 @@
</span><span class="cx">                 }
</span><span class="cx">                 $post_ID = (int) $post_ID;
</span><span class="cx"> 
</span><del>-                logIO(&quot;O&quot;,&quot;(PB) URL='$pagelinkedto' ID='$post_ID' Found='$way'&quot;);
-
</del><span class="cx">                 $post = get_post($post_ID);
</span><span class="cx"> 
</span><span class="cx">                 if ( !$post ) // Post_ID not found
</span></span></pre></div>
<a id="trunkwpincludesclasswpphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-wp.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-wp.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-includes/class-wp.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -15,7 +15,7 @@
</span><span class="cx">          * @access public
</span><span class="cx">          * @var array
</span><span class="cx">          */
</span><del>-        var $public_query_vars = array('m', 'p', 'posts', 'w', 'cat', 'withcomments', 'withoutcomments', 's', 'search', 'exact', 'sentence', 'debug', 'calendar', 'page', 'paged', 'more', 'tb', 'pb', 'author', 'order', 'orderby', 'year', 'monthnum', 'day', 'hour', 'minute', 'second', 'name', 'category_name', 'tag', 'feed', 'author_name', 'static', 'pagename', 'page_id', 'error', 'comments_popup', 'attachment', 'attachment_id', 'subpost', 'subpost_id', 'preview', 'robots', 'taxonomy', 'term', 'cpage', 'post_type');
</del><ins>+        var $public_query_vars = array('m', 'p', 'posts', 'w', 'cat', 'withcomments', 'withoutcomments', 's', 'search', 'exact', 'sentence', 'calendar', 'page', 'paged', 'more', 'tb', 'pb', 'author', 'order', 'orderby', 'year', 'monthnum', 'day', 'hour', 'minute', 'second', 'name', 'category_name', 'tag', 'feed', 'author_name', 'static', 'pagename', 'page_id', 'error', 'comments_popup', 'attachment', 'attachment_id', 'subpost', 'subpost_id', 'preview', 'robots', 'taxonomy', 'term', 'cpage', 'post_type');
</ins><span class="cx"> 
</span><span class="cx">         /**
</span><span class="cx">          * Private query variables.
</span></span></pre></div>
<a id="trunkwpincludesdeprecatedphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/deprecated.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/deprecated.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-includes/deprecated.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -2564,7 +2564,7 @@
</span><span class="cx">  * Is the current admin page generated by a plugin?
</span><span class="cx">  *
</span><span class="cx">  * @since 1.5.0
</span><del>- * @deprecated 3.1
</del><ins>+ * @deprecated 3.1.0
</ins><span class="cx">  * @deprecated Use global $plugin_page and/or get_plugin_page_hookname() hooks.
</span><span class="cx">  *
</span><span class="cx">  * @global $plugin_page
</span><span class="lines">@@ -2590,7 +2590,7 @@
</span><span class="cx">  * for updating the category cache.
</span><span class="cx">  *
</span><span class="cx">  * @since 1.5.0
</span><del>- * @deprecated 3.1
</del><ins>+ * @deprecated 3.1.0
</ins><span class="cx">  *
</span><span class="cx">  * @return bool Always return True
</span><span class="cx">  */
</span><span class="lines">@@ -2604,7 +2604,7 @@
</span><span class="cx">  * Check for PHP timezone support
</span><span class="cx">  *
</span><span class="cx">  * @since 2.9.0
</span><del>- * @deprecated 3.2
</del><ins>+ * @deprecated 3.2.0
</ins><span class="cx">  *
</span><span class="cx">  * @return bool
</span><span class="cx">  */
</span><span class="lines">@@ -2618,7 +2618,9 @@
</span><span class="cx">  * Display editor: TinyMCE, HTML, or both.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.1.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
+ * @deprecated Use wp_editor()
+ * @see wp_editor()
</ins><span class="cx">  *
</span><span class="cx">  * @param string $content Textarea content.
</span><span class="cx">  * @param string $id Optional, default is 'content'. HTML ID attribute value.
</span><span class="lines">@@ -2627,6 +2629,7 @@
</span><span class="cx">  * @param int $tab_index Optional, not used
</span><span class="cx">  */
</span><span class="cx"> function the_editor($content, $id = 'content', $prev_id = 'title', $media_buttons = true, $tab_index = 2, $extended = true) {
</span><ins>+        _deprecated_function( __FUNCTION__, '3.3', 'wp_editor()' );
</ins><span class="cx"> 
</span><span class="cx">         wp_editor( $content, $id, array( 'media_buttons' =&gt; $media_buttons ) );
</span><span class="cx">         return;
</span><span class="lines">@@ -2636,6 +2639,8 @@
</span><span class="cx">  * Perform the query to get the $metavalues array(s) needed by _fill_user and _fill_many_users
</span><span class="cx">  *
</span><span class="cx">  * @since 3.0.0
</span><ins>+ * @deprecated 3.3.0
+ *
</ins><span class="cx">  * @param array $ids User ID numbers list.
</span><span class="cx">  * @return array of arrays. The array is indexed by user_id, containing $metavalues object arrays.
</span><span class="cx">  */
</span><span class="lines">@@ -2668,7 +2673,6 @@
</span><span class="cx">  *
</span><span class="cx">  * @since 2.3.0
</span><span class="cx">  * @deprecated 3.3.0
</span><del>- * @uses sanitize_user_field() Used to sanitize the fields.
</del><span class="cx">  *
</span><span class="cx">  * @param object|array $user The User Object or Array
</span><span class="cx">  * @param string $context Optional, default is 'display'. How to sanitize user fields.
</span><span class="lines">@@ -2705,7 +2709,7 @@
</span><span class="cx">  * Can either be start or end post relational link.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  *
</span><span class="cx">  * @param string $title Optional. Link title format.
</span><span class="cx">  * @param bool $in_same_cat Optional. Whether link should be in a same category.
</span><span class="lines">@@ -2745,7 +2749,7 @@
</span><span class="cx">  * Display relational link for the first post.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  *
</span><span class="cx">  * @param string $title Optional. Link title format.
</span><span class="cx">  * @param bool $in_same_cat Optional. Whether link should be in a same category.
</span><span class="lines">@@ -2761,7 +2765,7 @@
</span><span class="cx">  * Get site index relational link.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  *
</span><span class="cx">  * @return string
</span><span class="cx">  */
</span><span class="lines">@@ -2776,7 +2780,7 @@
</span><span class="cx">  * Display relational link for the site index.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  */
</span><span class="cx"> function index_rel_link() {
</span><span class="cx">         _deprecated_function( __FUNCTION__, '3.3' );
</span><span class="lines">@@ -2788,7 +2792,7 @@
</span><span class="cx">  * Get parent post relational link.
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  *
</span><span class="cx">  * @param string $title Optional. Link title format.
</span><span class="cx">  * @return string
</span><span class="lines">@@ -2819,7 +2823,7 @@
</span><span class="cx">  * Display relational link for parent item
</span><span class="cx">  *
</span><span class="cx">  * @since 2.8.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  */
</span><span class="cx"> function parent_post_rel_link($title = '%title') {
</span><span class="cx">         _deprecated_function( __FUNCTION__, '3.3' );
</span><span class="lines">@@ -2831,7 +2835,7 @@
</span><span class="cx">  * Add the &quot;Dashboard&quot;/&quot;Visit Site&quot; menu.
</span><span class="cx">  *
</span><span class="cx">  * @since 3.2.0
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  */
</span><span class="cx"> function wp_admin_bar_dashboard_view_site_menu( $wp_admin_bar ) {
</span><span class="cx">         _deprecated_function( __FUNCTION__, '3.3' );
</span><span class="lines">@@ -2852,7 +2856,7 @@
</span><span class="cx">  * Checks if the current user belong to a given blog.
</span><span class="cx">  *
</span><span class="cx">  * @since MU
</span><del>- * @deprecated 3.3
</del><ins>+ * @deprecated 3.3.0
</ins><span class="cx">  * @deprecated Use is_user_member_of_blog()
</span><span class="cx">  * @see is_user_member_of_blog()
</span><span class="cx">  *
</span><span class="lines">@@ -2864,3 +2868,42 @@
</span><span class="cx"> 
</span><span class="cx">         return is_user_member_of_blog( get_current_user_id(), $blog_id );
</span><span class="cx"> }
</span><ins>+
+/**
+ * Open the file handle for debugging. 
+ *
+ * @since 0.71
+ * @deprecated Use error_log()
+ * @link http://www.php.net/manual/en/function.error-log.php
+ * @deprecated 3.4.0
+ */
+function debug_fopen( $filename, $mode ) {
+        _deprecated_function( __FUNCTION__, 'error_log()' );
+        return false;
+}
+
+/**
+ * Write contents to the file used for debugging.
+ *
+ * @since 0.71
+ * @deprecated Use error_log() instead.
+ * @link http://www.php.net/manual/en/function.error-log.php
+ * @deprecated 3.4.0
+ */
+function debug_fwrite( $fp, $string ) {
+        _deprecated_function( __FUNCTION__, 'error_log()' );
+        if ( ! empty( $GLOBALS['debug'] ) )
+                error_log( $string );
+}
+
+/**
+ * Close the debugging file handle.
+ *
+ * @since 0.71
+ * @deprecated Use error_log()
+ * @link http://www.php.net/manual/en/function.error-log.php
+ * @deprecated 3.4.0
+ */
+function debug_fclose( $fp ) {
+        _deprecated_function( __FUNCTION__, 'error_log()' );
+}
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="trunkwpincludesfunctionsphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/functions.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/functions.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/wp-includes/functions.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -395,71 +395,6 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> /**
</span><del>- * Open the file handle for debugging.
- *
- * This function is used for XMLRPC feature, but it is general purpose enough
- * to be used in anywhere.
- *
- * @see fopen() for mode options.
- * @package WordPress
- * @subpackage Debug
- * @since 0.71
- * @uses $debug Used for whether debugging is enabled.
- *
- * @param string $filename File path to debug file.
- * @param string $mode Same as fopen() mode parameter.
- * @return bool|resource File handle. False on failure.
- */
-function debug_fopen( $filename, $mode ) {
-        global $debug;
-        if ( 1 == $debug ) {
-                $fp = fopen( $filename, $mode );
-                return $fp;
-        } else {
-                return false;
-        }
-}
-
-/**
- * Write contents to the file used for debugging.
- *
- * Technically, this can be used to write to any file handle when the global
- * $debug is set to 1 or true.
- *
- * @package WordPress
- * @subpackage Debug
- * @since 0.71
- * @uses $debug Used for whether debugging is enabled.
- *
- * @param resource $fp File handle for debugging file.
- * @param string $string Content to write to debug file.
- */
-function debug_fwrite( $fp, $string ) {
-        global $debug;
-        if ( 1 == $debug )
-                fwrite( $fp, $string );
-}
-
-/**
- * Close the debugging file handle.
- *
- * Technically, this can be used to close any file handle when the global $debug
- * is set to 1 or true.
- *
- * @package WordPress
- * @subpackage Debug
- * @since 0.71
- * @uses $debug Used for whether debugging is enabled.
- *
- * @param resource $fp Debug File handle.
- */
-function debug_fclose( $fp ) {
-        global $debug;
-        if ( 1 == $debug )
-                fclose( $fp );
-}
-
-/**
</del><span class="cx">  * Check content for video and audio links to add as enclosures.
</span><span class="cx">  *
</span><span class="cx">  * Will not add enclosures that have already been added and will
</span><span class="lines">@@ -480,9 +415,7 @@
</span><span class="cx">         //TODO: Tidy this ghetto code up and make the debug code optional
</span><span class="cx">         include_once( ABSPATH . WPINC . '/class-IXR.php' );
</span><span class="cx"> 
</span><del>-        $log = debug_fopen( ABSPATH . 'enclosures.log', 'a' );
</del><span class="cx">         $post_links = array();
</span><del>-        debug_fwrite( $log, 'BEGIN ' . date( 'YmdHis', time() ) . &quot;\n&quot; );
</del><span class="cx"> 
</span><span class="cx">         $pung = get_enclosed( $post_ID );
</span><span class="cx"> 
</span><span class="lines">@@ -493,9 +426,6 @@
</span><span class="cx"> 
</span><span class="cx">         preg_match_all( &quot;{\b http : [$any] +? (?= [$punc] * [^$any] | $)}x&quot;, $content, $post_links_temp );
</span><span class="cx"> 
</span><del>-        debug_fwrite( $log, 'Post contents:' );
-        debug_fwrite( $log, $content . &quot;\n&quot; );
-
</del><span class="cx">         foreach ( $pung as $link_test ) {
</span><span class="cx">                 if ( !in_array( $link_test, $post_links_temp[0] ) ) { // link no longer in post
</span><span class="cx">                         $mid = $wpdb-&gt;get_col( $wpdb-&gt;prepare(&quot;SELECT meta_id FROM $wpdb-&gt;postmeta WHERE post_id = %d AND meta_key = 'enclosure' AND meta_value LIKE (%s)&quot;, $post_ID, like_escape( $link_test ) . '%') );
</span></span></pre></div>
<a id="trunkxmlrpcphp"></a>
<div class="modfile"><h4>Modified: trunk/xmlrpc.php (19934 => 19935)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/xmlrpc.php        2012-02-16 17:12:10 UTC (rev 19934)
+++ trunk/xmlrpc.php        2012-02-17 00:02:42 UTC (rev 19935)
</span><span class="lines">@@ -54,9 +54,6 @@
</span><span class="cx"> include_once(ABSPATH . WPINC . '/class-IXR.php');
</span><span class="cx"> include_once(ABSPATH . WPINC . '/class-wp-xmlrpc-server.php');
</span><span class="cx"> 
</span><del>-// Turn off all warnings and errors.
-// error_reporting(0);
-
</del><span class="cx"> /**
</span><span class="cx">  * Posts submitted via the xmlrpc interface get that title
</span><span class="cx">  * @name post_default_title
</span><span class="lines">@@ -64,43 +61,26 @@
</span><span class="cx">  */
</span><span class="cx"> $post_default_title = &quot;&quot;;
</span><span class="cx"> 
</span><del>-/**
- * Whether to enable XMLRPC Logging.
- *
- * @name xmlrpc_logging
- * @var int|bool
- */
-$xmlrpc_logging = 0;
</del><ins>+// Allow for a plugin to insert a different class to handle requests.
+$wp_xmlrpc_server_class = apply_filters('wp_xmlrpc_server_class', 'wp_xmlrpc_server');
+$wp_xmlrpc_server = new $wp_xmlrpc_server_class;
</ins><span class="cx"> 
</span><ins>+// Fire off the request
+$wp_xmlrpc_server-&gt;serve_request();
+
+exit;
+
</ins><span class="cx"> /**
</span><span class="cx">  * logIO() - Writes logging info to a file.
</span><span class="cx">  *
</span><del>- * @uses $xmlrpc_logging
- * @package WordPress
- * @subpackage Logging
</del><ins>+ * @deprecated 3.4.0
+ * @deprecated Use error_log()
</ins><span class="cx">  *
</span><span class="cx">  * @param string $io Whether input or output
</span><span class="cx">  * @param string $msg Information describing logging reason.
</span><del>- * @return bool Always return true
</del><span class="cx">  */
</span><del>-function logIO($io,$msg) {
-        global $xmlrpc_logging;
-        if ($xmlrpc_logging) {
-                $fp = fopen(&quot;../xmlrpc.log&quot;,&quot;a+&quot;);
-                $date = gmdate(&quot;Y-m-d H:i:s &quot;);
-                $iot = ($io == &quot;I&quot;) ? &quot; Input: &quot; : &quot; Output: &quot;;
-                fwrite($fp, &quot;\n\n&quot;.$date.$iot.$msg);
-                fclose($fp);
-        }
-        return true;
-}
-
-if ( isset($HTTP_RAW_POST_DATA) )
-        logIO(&quot;I&quot;, $HTTP_RAW_POST_DATA);
-
-// Allow for a plugin to insert a different class to handle requests.
-$wp_xmlrpc_server_class = apply_filters('wp_xmlrpc_server_class', 'wp_xmlrpc_server');
-$wp_xmlrpc_server = new $wp_xmlrpc_server_class;
-
-// Fire off the request
-$wp_xmlrpc_server-&gt;serve_request();
</del><ins>+function logIO( $io, $msg ) {
+        _deprecated_function( __FUNCTION__, '3.4', 'error_log()' );
+        if ( ! empty( $GLOBALS['xmlrpc_logging'] ) )
+                error_log( $io . ' - ' . $msg );
+}
</ins><span class="cx">\ No newline at end of file
</span></span></pre>
</div>
</div>

</body>
</html>