<!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>[19094] trunk/wp-includes: Avoid E_STRICT notices.</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/19094">19094</a></dd>
<dt>Author</dt> <dd>ryan</dd>
<dt>Date</dt> <dd>2011-10-31 19:38:46 +0000 (Mon, 31 Oct 2011)</dd>
</dl>

<h3>Log Message</h3>
<pre>Avoid E_STRICT notices. see <a href="http://core.trac.wordpress.org/ticket/18975">#18975</a></pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpincludesclasshttpphp">trunk/wp-includes/class-http.php</a></li>
<li><a href="#trunkwpincludesclasswpphp">trunk/wp-includes/class-wp.php</a></li>
<li><a href="#trunkwpincludesgeneraltemplatephp">trunk/wp-includes/general-template.php</a></li>
<li><a href="#trunkwpincludesmsloadphp">trunk/wp-includes/ms-load.php</a></li>
<li><a href="#trunkwpincludespostphp">trunk/wp-includes/post.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpincludesclasshttpphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-http.php (19093 => 19094)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-http.php        2011-10-31 17:08:36 UTC (rev 19093)
+++ trunk/wp-includes/class-http.php        2011-10-31 19:38:46 UTC (rev 19094)
</span><span class="lines">@@ -346,7 +346,7 @@
</span><span class="cx">          * @return array Processed string headers. If duplicate headers are encountered,
</span><span class="cx">          *                                         Then a numbered array is returned as the value of that header-key.
</span><span class="cx">          */
</span><del>-        function processHeaders($headers) {
</del><ins>+        public static function processHeaders($headers) {
</ins><span class="cx">                 // split headers, one per array element
</span><span class="cx">                 if ( is_string($headers) ) {
</span><span class="cx">                         // tolerate line terminator: CRLF = LF (RFC 2616 19.3)
</span><span class="lines">@@ -413,7 +413,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @param array $r Full array of args passed into ::request()
</span><span class="cx">          */
</span><del>-        function buildCookieHeader( &amp;$r ) {
</del><ins>+        public static function buildCookieHeader( &amp;$r ) {
</ins><span class="cx">                 if ( ! empty($r['cookies']) ) {
</span><span class="cx">                         $cookies_header = '';
</span><span class="cx">                         foreach ( (array) $r['cookies'] as $cookie ) {
</span><span class="lines">@@ -756,7 +756,7 @@
</span><span class="cx">          * @static
</span><span class="cx">          * @return boolean False means this class can not be used, true means it can.
</span><span class="cx">          */
</span><del>-        function test( $args = array() ) {
</del><ins>+        public static function test( $args = array() ) {
</ins><span class="cx">                 if ( ! function_exists( 'fsockopen' ) )
</span><span class="cx">                         return false;
</span><span class="cx"> 
</span><span class="lines">@@ -939,7 +939,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @return boolean False means this class can not be used, true means it can.
</span><span class="cx">          */
</span><del>-        function test( $args = array() ) {
</del><ins>+        public static function test( $args = array() ) {
</ins><span class="cx">                 if ( ! function_exists( 'fopen' ) )
</span><span class="cx">                         return false;
</span><span class="cx"> 
</span><span class="lines">@@ -1166,7 +1166,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @return boolean False means this class can not be used, true means it can.
</span><span class="cx">          */
</span><del>-        function test( $args = array() ) {
</del><ins>+        public static function test( $args = array() ) {
</ins><span class="cx">                 if ( ! function_exists( 'curl_init' ) || ! function_exists( 'curl_exec' ) )
</span><span class="cx">                         return false;
</span><span class="cx"> 
</span><span class="lines">@@ -1580,7 +1580,7 @@
</span><span class="cx">          * @param string $supports Optional, not used. When implemented it will choose the right compression based on what the server supports.
</span><span class="cx">          * @return string|bool False on failure.
</span><span class="cx">          */
</span><del>-        function compress( $raw, $level = 9, $supports = null ) {
</del><ins>+        public static function compress( $raw, $level = 9, $supports = null ) {
</ins><span class="cx">                 return gzdeflate( $raw, $level );
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1598,7 +1598,7 @@
</span><span class="cx">          * @param int $length The optional length of the compressed data.
</span><span class="cx">          * @return string|bool False on failure.
</span><span class="cx">          */
</span><del>-        function decompress( $compressed, $length = null ) {
</del><ins>+        public static function decompress( $compressed, $length = null ) {
</ins><span class="cx"> 
</span><span class="cx">                 if ( empty($compressed) )
</span><span class="cx">                         return $compressed;
</span><span class="lines">@@ -1642,7 +1642,7 @@
</span><span class="cx">          * @param string $gzData String to decompress.
</span><span class="cx">          * @return string|bool False on failure.
</span><span class="cx">          */
</span><del>-        function compatible_gzinflate($gzData) {
</del><ins>+        public static function compatible_gzinflate($gzData) {
</ins><span class="cx"> 
</span><span class="cx">                 // Compressed data might contain a full header, if so strip it for gzinflate()
</span><span class="cx">                 if ( substr($gzData, 0, 3) == &quot;\x1f\x8b\x08&quot; ) {
</span><span class="lines">@@ -1680,7 +1680,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @return string Types of encoding to accept.
</span><span class="cx">          */
</span><del>-        function accept_encoding() {
</del><ins>+        public static function accept_encoding() {
</ins><span class="cx">                 $type = array();
</span><span class="cx">                 if ( function_exists( 'gzinflate' ) )
</span><span class="cx">                         $type[] = 'deflate;q=1.0';
</span><span class="lines">@@ -1701,7 +1701,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @return string Content-Encoding string to send in the header.
</span><span class="cx">          */
</span><del>-        function content_encoding() {
</del><ins>+        public static function content_encoding() {
</ins><span class="cx">                 return 'deflate';
</span><span class="cx">         }
</span><span class="cx"> 
</span><span class="lines">@@ -1713,7 +1713,7 @@
</span><span class="cx">          * @param array|string $headers All of the available headers.
</span><span class="cx">          * @return bool
</span><span class="cx">          */
</span><del>-        function should_decode($headers) {
</del><ins>+        public static function should_decode($headers) {
</ins><span class="cx">                 if ( is_array( $headers ) ) {
</span><span class="cx">                         if ( array_key_exists('content-encoding', $headers) &amp;&amp; ! empty( $headers['content-encoding'] ) )
</span><span class="cx">                                 return true;
</span><span class="lines">@@ -1735,7 +1735,7 @@
</span><span class="cx">          *
</span><span class="cx">          * @return bool
</span><span class="cx">          */
</span><del>-        function is_available() {
</del><ins>+        public static function is_available() {
</ins><span class="cx">                 return ( function_exists('gzuncompress') || function_exists('gzdeflate') || function_exists('gzinflate') );
</span><span class="cx">         }
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkwpincludesclasswpphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-wp.php (19093 => 19094)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-wp.php        2011-10-31 17:08:36 UTC (rev 19093)
+++ trunk/wp-includes/class-wp.php        2011-10-31 19:38:46 UTC (rev 19094)
</span><span class="lines">@@ -572,7 +572,7 @@
</span><span class="cx">          * @param array  $matches data used for substitution
</span><span class="cx">          * @return string
</span><span class="cx">          */
</span><del>-        function apply($subject, $matches) {
</del><ins>+        public static function apply($subject, $matches) {
</ins><span class="cx">                 $oSelf = new WP_MatchesMapRegex($subject, $matches);
</span><span class="cx">                 return $oSelf-&gt;output;
</span><span class="cx">         }
</span></span></pre></div>
<a id="trunkwpincludesgeneraltemplatephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/general-template.php (19093 => 19094)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/general-template.php        2011-10-31 17:08:36 UTC (rev 19093)
+++ trunk/wp-includes/general-template.php        2011-10-31 19:38:46 UTC (rev 19094)
</span><span class="lines">@@ -1621,7 +1621,8 @@
</span><span class="cx">         $args = wp_parse_args( $args, $defaults );
</span><span class="cx"> 
</span><span class="cx">         if ( is_single() || is_page() ) {
</span><del>-                $post = &amp;get_post( $id = 0 );
</del><ins>+                $id = 0;
+                $post = &amp;get_post( $id );
</ins><span class="cx"> 
</span><span class="cx">                 if ( comments_open() || pings_open() || $post-&gt;comment_count &gt; 0 ) {
</span><span class="cx">                         $title = esc_attr(sprintf( $args['singletitle'], get_bloginfo('name'), $args['separator'], esc_html( get_the_title() ) ));
</span></span></pre></div>
<a id="trunkwpincludesmsloadphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/ms-load.php (19093 => 19094)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/ms-load.php        2011-10-31 17:08:36 UTC (rev 19093)
+++ trunk/wp-includes/ms-load.php        2011-10-31 19:38:46 UTC (rev 19094)
</span><span class="lines">@@ -134,6 +134,10 @@
</span><span class="cx">  */
</span><span class="cx"> function wpmu_current_site() {
</span><span class="cx">         global $wpdb, $current_site, $domain, $path, $sites, $cookie_domain;
</span><ins>+
+        if ( empty( $current_site ) )
+                $current_site = new stdClass;
+
</ins><span class="cx">         if ( defined( 'DOMAIN_CURRENT_SITE' ) &amp;&amp; defined( 'PATH_CURRENT_SITE' ) ) {
</span><span class="cx">                 $current_site-&gt;id = defined( 'SITE_ID_CURRENT_SITE' ) ? SITE_ID_CURRENT_SITE : 1;
</span><span class="cx">                 $current_site-&gt;domain = DOMAIN_CURRENT_SITE;
</span></span></pre></div>
<a id="trunkwpincludespostphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/post.php (19093 => 19094)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/post.php        2011-10-31 17:08:36 UTC (rev 19093)
+++ trunk/wp-includes/post.php        2011-10-31 19:38:46 UTC (rev 19094)
</span><span class="lines">@@ -4027,7 +4027,8 @@
</span><span class="cx">                         $dirs = apply_filters( 'icon_dirs', array($icon_dir =&gt; $icon_dir_uri) );
</span><span class="cx">                         $icon_files = array();
</span><span class="cx">                         while ( $dirs ) {
</span><del>-                                $dir = array_shift($keys = array_keys($dirs));
</del><ins>+                                $keys = array_keys( $dirs );
+                                $dir = array_shift( $keys );
</ins><span class="cx">                                 $uri = array_shift($dirs);
</span><span class="cx">                                 if ( $dh = opendir($dir) ) {
</span><span class="cx">                                         while ( false !== $file = readdir($dh) ) {
</span></span></pre>
</div>
</div>

</body>
</html>