<!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" /><style type="text/css"><!--
#msg dl { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer { 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 #fc0 solid; padding: 6px; }
#msg ul, pre { overflow: auto; }
#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>
<title>[16340] trunk: Use square brackets instead of braces for string access.</title>
</head>
<body>

<div id="msg">
<dl>
<dt>Revision</dt> <dd><a href="http://trac.wordpress.org/changeset/16340">16340</a></dd>
<dt>Author</dt> <dd>nacin</dd>
<dt>Date</dt> <dd>2010-11-13 09:53:55 +0000 (Sat, 13 Nov 2010)</dd>
</dl>

<h3>Log Message</h3>
<pre>Use square brackets instead of braces for string access. props hakre, fixes <a href="http://trac.wordpress.org/ticket/13900">#13900</a>.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkwpadminimportphp">trunk/wp-admin/import.php</a></li>
<li><a href="#trunkwpadminincludesmediaphp">trunk/wp-admin/includes/media.php</a></li>
<li><a href="#trunkwpadminincludesmiscphp">trunk/wp-admin/includes/misc.php</a></li>
<li><a href="#trunkwpincludesclassjsonphp">trunk/wp-includes/class-json.php</a></li>
<li><a href="#trunkwpincludesclasspop3php">trunk/wp-includes/class-pop3.php</a></li>
<li><a href="#trunkwpincludesformattingphp">trunk/wp-includes/formatting.php</a></li>
<li><a href="#trunkwpincludesfunctionsphp">trunk/wp-includes/functions.php</a></li>
<li><a href="#trunkwpincludespluggablephp">trunk/wp-includes/pluggable.php</a></li>
<li><a href="#trunkwpincludesposttemplatephp">trunk/wp-includes/post-template.php</a></li>
<li><a href="#trunkwpincludesrewritephp">trunk/wp-includes/rewrite.php</a></li>
<li><a href="#trunkwpincludesthemephp">trunk/wp-includes/theme.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkwpadminimportphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/import.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/import.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-admin/import.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -62,7 +62,7 @@
</span><span class="cx"> $imports_dir = @ opendir($import_root);
</span><span class="cx"> if ($imports_dir) {
</span><span class="cx">         while (($file = readdir($imports_dir)) !== false) {
</span><del>-                if ($file{0} == '.') {
</del><ins>+                if ($file[0] == '.') {
</ins><span class="cx">                         continue;
</span><span class="cx">                 } elseif (substr($file, -4) == '.php') {
</span><span class="cx">                         require_once($import_root . '/' . $file);
</span></span></pre></div>
<a id="trunkwpadminincludesmediaphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/includes/media.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/includes/media.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-admin/includes/media.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -1258,7 +1258,7 @@
</span><span class="cx">         $hidden_fields = array();
</span><span class="cx"> 
</span><span class="cx">         foreach ( $form_fields as $id =&gt; $field ) {
</span><del>-                if ( $id{0} == '_' )
</del><ins>+                if ( $id[0] == '_' )
</ins><span class="cx">                         continue;
</span><span class="cx"> 
</span><span class="cx">                 if ( !empty( $field['tr'] ) ) {
</span></span></pre></div>
<a id="trunkwpadminincludesmiscphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-admin/includes/misc.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-admin/includes/misc.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-admin/includes/misc.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -576,7 +576,7 @@
</span><span class="cx">          * see http://bugs.php.net/bug.php?id=30931
</span><span class="cx">          */
</span><span class="cx"> 
</span><del>-    if ( $path{strlen($path)-1} == '/' ) // recursively return a temporary file path
</del><ins>+    if ( $path[strlen($path)-1] == '/' ) // recursively return a temporary file path
</ins><span class="cx">         return win_is_writable($path . uniqid(mt_rand()) . '.tmp');
</span><span class="cx">     else if ( is_dir($path) )
</span><span class="cx">         return win_is_writable($path . '/' . uniqid(mt_rand()) . '.tmp');
</span></span></pre></div>
<a id="trunkwpincludesclassjsonphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-json.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-json.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/class-json.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -153,7 +153,7 @@
</span><span class="cx">                         return mb_convert_encoding($utf16, 'UTF-8', 'UTF-16');
</span><span class="cx">                 }
</span><span class="cx"> 
</span><del>-                $bytes = (ord($utf16{0}) &lt;&lt; 8) | ord($utf16{1});
</del><ins>+                $bytes = (ord($utf16[0]) &lt;&lt; 8) | ord($utf16[1]);
</ins><span class="cx"> 
</span><span class="cx">                 switch(true) {
</span><span class="cx">                         case ((0x7F &amp; $bytes) == $bytes):
</span><span class="lines">@@ -206,17 +206,17 @@
</span><span class="cx">                         case 2:
</span><span class="cx">                                 // return a UTF-16 character from a 2-byte UTF-8 char
</span><span class="cx">                                 // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
</span><del>-                                return chr(0x07 &amp; (ord($utf8{0}) &gt;&gt; 2))
-                                        . chr((0xC0 &amp; (ord($utf8{0}) &lt;&lt; 6))
-                                                | (0x3F &amp; ord($utf8{1})));
</del><ins>+                                return chr(0x07 &amp; (ord($utf8[0]) &gt;&gt; 2))
+                                        . chr((0xC0 &amp; (ord($utf8[0]) &lt;&lt; 6))
+                                                | (0x3F &amp; ord($utf8[1])));
</ins><span class="cx"> 
</span><span class="cx">                         case 3:
</span><span class="cx">                                 // return a UTF-16 character from a 3-byte UTF-8 char
</span><span class="cx">                                 // see: http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
</span><del>-                                return chr((0xF0 &amp; (ord($utf8{0}) &lt;&lt; 4))
-                                                | (0x0F &amp; (ord($utf8{1}) &gt;&gt; 2)))
-                                        . chr((0xC0 &amp; (ord($utf8{1}) &lt;&lt; 6))
-                                                | (0x7F &amp; ord($utf8{2})));
</del><ins>+                                return chr((0xF0 &amp; (ord($utf8[0]) &lt;&lt; 4))
+                                                | (0x0F &amp; (ord($utf8[1]) &gt;&gt; 2)))
+                                        . chr((0xC0 &amp; (ord($utf8[1]) &lt;&lt; 6))
+                                                | (0x7F &amp; ord($utf8[2])));
</ins><span class="cx">                 }
</span><span class="cx"> 
</span><span class="cx">                 // ignoring UTF-32 for now, sorry
</span><span class="lines">@@ -293,7 +293,7 @@
</span><span class="cx">                                 */
</span><span class="cx">                                 for ($c = 0; $c &lt; $strlen_var; ++$c) {
</span><span class="cx"> 
</span><del>-                                        $ord_var_c = ord($var{$c});
</del><ins>+                                        $ord_var_c = ord($var[$c]);
</ins><span class="cx"> 
</span><span class="cx">                                         switch (true) {
</span><span class="cx">                                                 case $ord_var_c == 0x08:
</span><span class="lines">@@ -316,12 +316,12 @@
</span><span class="cx">                                                 case $ord_var_c == 0x2F:
</span><span class="cx">                                                 case $ord_var_c == 0x5C:
</span><span class="cx">                                                         // double quote, slash, slosh
</span><del>-                                                        $ascii .= '\\'.$var{$c};
</del><ins>+                                                        $ascii .= '\\'.$var[$c];
</ins><span class="cx">                                                         break;
</span><span class="cx"> 
</span><span class="cx">                                                 case (($ord_var_c &gt;= 0x20) &amp;&amp; ($ord_var_c &lt;= 0x7F)):
</span><span class="cx">                                                         // characters U-00000000 - U-0000007F (same as ASCII)
</span><del>-                                                        $ascii .= $var{$c};
</del><ins>+                                                        $ascii .= $var[$c];
</ins><span class="cx">                                                         break;
</span><span class="cx"> 
</span><span class="cx">                                                 case (($ord_var_c &amp; 0xE0) == 0xC0):
</span><span class="lines">@@ -333,7 +333,7 @@
</span><span class="cx">                                                                 break;
</span><span class="cx">                                                         }
</span><span class="cx"> 
</span><del>-                                                        $char = pack('C*', $ord_var_c, ord($var{$c + 1}));
</del><ins>+                                                        $char = pack('C*', $ord_var_c, ord($var[$c + 1]));
</ins><span class="cx">                                                         $c += 1;
</span><span class="cx">                                                         $utf16 = $this-&gt;utf82utf16($char);
</span><span class="cx">                                                         $ascii .= sprintf('\u%04s', bin2hex($utf16));
</span><span class="lines">@@ -348,8 +348,8 @@
</span><span class="cx">                                                         // characters U-00000800 - U-0000FFFF, mask 1110XXXX
</span><span class="cx">                                                         // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
</span><span class="cx">                                                         $char = pack('C*', $ord_var_c,
</span><del>-                                                                                @ord($var{$c + 1}),
-                                                                                @ord($var{$c + 2}));
</del><ins>+                                                                                @ord($var[$c + 1]),
+                                                                                @ord($var[$c + 2]));
</ins><span class="cx">                                                         $c += 2;
</span><span class="cx">                                                         $utf16 = $this-&gt;utf82utf16($char);
</span><span class="cx">                                                         $ascii .= sprintf('\u%04s', bin2hex($utf16));
</span><span class="lines">@@ -364,9 +364,9 @@
</span><span class="cx">                                                         // characters U-00010000 - U-001FFFFF, mask 11110XXX
</span><span class="cx">                                                         // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
</span><span class="cx">                                                         $char = pack('C*', $ord_var_c,
</span><del>-                                                                                ord($var{$c + 1}),
-                                                                                ord($var{$c + 2}),
-                                                                                ord($var{$c + 3}));
</del><ins>+                                                                                ord($var[$c + 1]),
+                                                                                ord($var[$c + 2]),
+                                                                                ord($var[$c + 3]));
</ins><span class="cx">                                                         $c += 3;
</span><span class="cx">                                                         $utf16 = $this-&gt;utf82utf16($char);
</span><span class="cx">                                                         $ascii .= sprintf('\u%04s', bin2hex($utf16));
</span><span class="lines">@@ -381,10 +381,10 @@
</span><span class="cx">                                                                 break;
</span><span class="cx">                                                         }
</span><span class="cx">                                                         $char = pack('C*', $ord_var_c,
</span><del>-                                                                                ord($var{$c + 1}),
-                                                                                ord($var{$c + 2}),
-                                                                                ord($var{$c + 3}),
-                                                                                ord($var{$c + 4}));
</del><ins>+                                                                                ord($var[$c + 1]),
+                                                                                ord($var[$c + 2]),
+                                                                                ord($var[$c + 3]),
+                                                                                ord($var[$c + 4]));
</ins><span class="cx">                                                         $c += 4;
</span><span class="cx">                                                         $utf16 = $this-&gt;utf82utf16($char);
</span><span class="cx">                                                         $ascii .= sprintf('\u%04s', bin2hex($utf16));
</span><span class="lines">@@ -399,11 +399,11 @@
</span><span class="cx">                                                         // characters U-04000000 - U-7FFFFFFF, mask 1111110X
</span><span class="cx">                                                         // see http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8
</span><span class="cx">                                                         $char = pack('C*', $ord_var_c,
</span><del>-                                                                                ord($var{$c + 1}),
-                                                                                ord($var{$c + 2}),
-                                                                                ord($var{$c + 3}),
-                                                                                ord($var{$c + 4}),
-                                                                                ord($var{$c + 5}));
</del><ins>+                                                                                ord($var[$c + 1]),
+                                                                                ord($var[$c + 2]),
+                                                                                ord($var[$c + 3]),
+                                                                                ord($var[$c + 4]),
+                                                                                ord($var[$c + 5]));
</ins><span class="cx">                                                         $c += 5;
</span><span class="cx">                                                         $utf16 = $this-&gt;utf82utf16($char);
</span><span class="cx">                                                         $ascii .= sprintf('\u%04s', bin2hex($utf16));
</span><span class="lines">@@ -577,7 +577,7 @@
</span><span class="cx">                                         for ($c = 0; $c &lt; $strlen_chrs; ++$c) {
</span><span class="cx"> 
</span><span class="cx">                                                 $substr_chrs_c_2 = substr($chrs, $c, 2);
</span><del>-                                                $ord_chrs_c = ord($chrs{$c});
</del><ins>+                                                $ord_chrs_c = ord($chrs[$c]);
</ins><span class="cx"> 
</span><span class="cx">                                                 switch (true) {
</span><span class="cx">                                                         case $substr_chrs_c_2 == '\b':
</span><span class="lines">@@ -607,7 +607,7 @@
</span><span class="cx">                                                         case $substr_chrs_c_2 == '\\/':
</span><span class="cx">                                                                 if (($delim == '&quot;' &amp;&amp; $substr_chrs_c_2 != '\\\'') ||
</span><span class="cx">                                                                 ($delim == &quot;'&quot; &amp;&amp; $substr_chrs_c_2 != '\\&quot;')) {
</span><del>-                                                                        $utf8 .= $chrs{++$c};
</del><ins>+                                                                        $utf8 .= $chrs[++$c];
</ins><span class="cx">                                                                 }
</span><span class="cx">                                                                 break;
</span><span class="cx"> 
</span><span class="lines">@@ -620,7 +620,7 @@
</span><span class="cx">                                                                 break;
</span><span class="cx"> 
</span><span class="cx">                                                         case ($ord_chrs_c &gt;= 0x20) &amp;&amp; ($ord_chrs_c &lt;= 0x7F):
</span><del>-                                                                $utf8 .= $chrs{$c};
</del><ins>+                                                                $utf8 .= $chrs[$c];
</ins><span class="cx">                                                                 break;
</span><span class="cx"> 
</span><span class="cx">                                                         case ($ord_chrs_c &amp; 0xE0) == 0xC0:
</span><span class="lines">@@ -667,7 +667,7 @@
</span><span class="cx">                                 } elseif (preg_match('/^\[.*\]$/s', $str) || preg_match('/^\{.*\}$/s', $str)) {
</span><span class="cx">                                         // array, or object notation
</span><span class="cx"> 
</span><del>-                                        if ($str{0} == '[') {
</del><ins>+                                        if ($str[0] == '[') {
</ins><span class="cx">                                                 $stk = array(SERVICES_JSON_IN_ARR);
</span><span class="cx">                                                 $arr = array();
</span><span class="cx">                                         } else {
</span><span class="lines">@@ -706,7 +706,7 @@
</span><span class="cx">                                                 $top = end($stk);
</span><span class="cx">                                                 $substr_chrs_c_2 = substr($chrs, $c, 2);
</span><span class="cx"> 
</span><del>-                                                if (($c == $strlen_chrs) || (($chrs{$c} == ',') &amp;&amp; ($top['what'] == SERVICES_JSON_SLICE))) {
</del><ins>+                                                if (($c == $strlen_chrs) || (($chrs[$c] == ',') &amp;&amp; ($top['what'] == SERVICES_JSON_SLICE))) {
</ins><span class="cx">                                                         // found a comma that is not inside a string, array, etc.,
</span><span class="cx">                                                         // OR we've reached the end of the character list
</span><span class="cx">                                                         $slice = substr($chrs, $top['where'], ($c - $top['where']));
</span><span class="lines">@@ -748,12 +748,12 @@
</span><span class="cx"> 
</span><span class="cx">                                                         }
</span><span class="cx"> 
</span><del>-                                                } elseif ((($chrs{$c} == '&quot;') || ($chrs{$c} == &quot;'&quot;)) &amp;&amp; ($top['what'] != SERVICES_JSON_IN_STR)) {
</del><ins>+                                                } elseif ((($chrs[$c] == '&quot;') || ($chrs[$c] == &quot;'&quot;)) &amp;&amp; ($top['what'] != SERVICES_JSON_IN_STR)) {
</ins><span class="cx">                                                         // found a quote, and we are not inside a string
</span><del>-                                                        array_push($stk, array('what' =&gt; SERVICES_JSON_IN_STR, 'where' =&gt; $c, 'delim' =&gt; $chrs{$c}));
</del><ins>+                                                        array_push($stk, array('what' =&gt; SERVICES_JSON_IN_STR, 'where' =&gt; $c, 'delim' =&gt; $chrs[$c]));
</ins><span class="cx">                                                         //print(&quot;Found start of string at {$c}\n&quot;);
</span><span class="cx"> 
</span><del>-                                                } elseif (($chrs{$c} == $top['delim']) &amp;&amp;
</del><ins>+                                                } elseif (($chrs[$c] == $top['delim']) &amp;&amp;
</ins><span class="cx">                                                                 ($top['what'] == SERVICES_JSON_IN_STR) &amp;&amp;
</span><span class="cx">                                                                 ((strlen(substr($chrs, 0, $c)) - strlen(rtrim(substr($chrs, 0, $c), '\\'))) % 2 != 1)) {
</span><span class="cx">                                                         // found a quote, we're in a string, and it's not escaped
</span><span class="lines">@@ -762,24 +762,24 @@
</span><span class="cx">                                                         array_pop($stk);
</span><span class="cx">                                                         //print(&quot;Found end of string at {$c}: &quot;.substr($chrs, $top['where'], (1 + 1 + $c - $top['where'])).&quot;\n&quot;);
</span><span class="cx"> 
</span><del>-                                                } elseif (($chrs{$c} == '[') &amp;&amp;
</del><ins>+                                                } elseif (($chrs[$c] == '[') &amp;&amp;
</ins><span class="cx">                                                                 in_array($top['what'], array(SERVICES_JSON_SLICE, SERVICES_JSON_IN_ARR, SERVICES_JSON_IN_OBJ))) {
</span><span class="cx">                                                         // found a left-bracket, and we are in an array, object, or slice
</span><span class="cx">                                                         array_push($stk, array('what' =&gt; SERVICES_JSON_IN_ARR, 'where' =&gt; $c, 'delim' =&gt; false));
</span><span class="cx">                                                         //print(&quot;Found start of array at {$c}\n&quot;);
</span><span class="cx"> 
</span><del>-                                                } elseif (($chrs{$c} == ']') &amp;&amp; ($top['what'] == SERVICES_JSON_IN_ARR)) {
</del><ins>+                                                } elseif (($chrs[$c] == ']') &amp;&amp; ($top['what'] == SERVICES_JSON_IN_ARR)) {
</ins><span class="cx">                                                         // found a right-bracket, and we're in an array
</span><span class="cx">                                                         array_pop($stk);
</span><span class="cx">                                                         //print(&quot;Found end of array at {$c}: &quot;.substr($chrs, $top['where'], (1 + $c - $top['where'])).&quot;\n&quot;);
</span><span class="cx"> 
</span><del>-                                                } elseif (($chrs{$c} == '{') &amp;&amp;
</del><ins>+                                                } elseif (($chrs[$c] == '{') &amp;&amp;
</ins><span class="cx">                                                                 in_array($top['what'], array(SERVICES_JSON_SLICE, SERVICES_JSON_IN_ARR, SERVICES_JSON_IN_OBJ))) {
</span><span class="cx">                                                         // found a left-brace, and we are in an array, object, or slice
</span><span class="cx">                                                         array_push($stk, array('what' =&gt; SERVICES_JSON_IN_OBJ, 'where' =&gt; $c, 'delim' =&gt; false));
</span><span class="cx">                                                         //print(&quot;Found start of object at {$c}\n&quot;);
</span><span class="cx"> 
</span><del>-                                                } elseif (($chrs{$c} == '}') &amp;&amp; ($top['what'] == SERVICES_JSON_IN_OBJ)) {
</del><ins>+                                                } elseif (($chrs[$c] == '}') &amp;&amp; ($top['what'] == SERVICES_JSON_IN_OBJ)) {
</ins><span class="cx">                                                         // found a right-brace, and we're in an object
</span><span class="cx">                                                         array_pop($stk);
</span><span class="cx">                                                         //print(&quot;Found end of object at {$c}: &quot;.substr($chrs, $top['where'], (1 + $c - $top['where'])).&quot;\n&quot;);
</span></span></pre></div>
<a id="trunkwpincludesclasspop3php"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/class-pop3.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/class-pop3.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/class-pop3.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -367,7 +367,7 @@
</span><span class="cx">         $line = fgets($fp,$buffer);
</span><span class="cx">         while ( !ereg(&quot;^\.\r\n&quot;,$line))
</span><span class="cx">         {
</span><del>-            if ( $line{0} == '.' ) { $line = substr($line,1); }
</del><ins>+            if ( $line[0] == '.' ) { $line = substr($line,1); }
</ins><span class="cx">             $MsgArray[$count] = $line;
</span><span class="cx">             $count++;
</span><span class="cx">             $line = fgets($fp,$buffer);
</span></span></pre></div>
<a id="trunkwpincludesformattingphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/formatting.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/formatting.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/formatting.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -92,7 +92,7 @@
</span><span class="cx">         for ( $i = 0; $i &lt; $stop; $i++ ) {
</span><span class="cx">                 $curl = $textarr[$i];
</span><span class="cx"> 
</span><del>-                if ( !empty($curl) &amp;&amp; '&lt;' != $curl{0} &amp;&amp; '[' != $curl{0}
</del><ins>+                if ( !empty($curl) &amp;&amp; '&lt;' != $curl[0] &amp;&amp; '[' != $curl[0]
</ins><span class="cx">                                 &amp;&amp; empty($no_texturize_shortcodes_stack) &amp;&amp; empty($no_texturize_tags_stack)) {
</span><span class="cx">                         // This is not a tag, nor is the texturization disabled
</span><span class="cx">                         // static strings
</span><span class="lines">@@ -113,9 +113,9 @@
</span><span class="cx">                          * Only call _wptexturize_pushpop_element if first char is correct
</span><span class="cx">                          * tag opening
</span><span class="cx">                          */
</span><del>-                        if ('&lt;' == $curl{0})
</del><ins>+                        if ('&lt;' == $curl[0])
</ins><span class="cx">                                 _wptexturize_pushpop_element($curl, $no_texturize_tags_stack, $no_texturize_tags, '&lt;', '&gt;');
</span><del>-                        elseif ('[' == $curl{0})
</del><ins>+                        elseif ('[' == $curl[0])
</ins><span class="cx">                                 _wptexturize_pushpop_element($curl, $no_texturize_shortcodes_stack, $no_texturize_shortcodes, '[', ']');
</span><span class="cx">                 }
</span><span class="cx"> 
</span><span class="lines">@@ -1498,7 +1498,7 @@
</span><span class="cx">                 $stop = count($textarr);// loop stuff
</span><span class="cx">                 for ($i = 0; $i &lt; $stop; $i++) {
</span><span class="cx">                         $content = $textarr[$i];
</span><del>-                        if ((strlen($content) &gt; 0) &amp;&amp; ('&lt;' != $content{0})) { // If it's not a tag
</del><ins>+                        if ((strlen($content) &gt; 0) &amp;&amp; ('&lt;' != $content[0])) { // If it's not a tag
</ins><span class="cx">                                 $content = preg_replace_callback($wp_smiliessearch, 'translate_smiley', $content);
</span><span class="cx">                         }
</span><span class="cx">                         $output .= $content;
</span><span class="lines">@@ -2632,7 +2632,7 @@
</span><span class="cx">                 $fragment = substr($pattern, $start, $end - $start);
</span><span class="cx"> 
</span><span class="cx">                 // Fragment has a specifier
</span><del>-                if ( $pattern{$start} == '%' ) {
</del><ins>+                if ( $pattern[$start] == '%' ) {
</ins><span class="cx">                         // Find numbered arguments or take the next one in order
</span><span class="cx">                         if ( preg_match('/^%(\d+)\$/', $fragment, $matches) ) {
</span><span class="cx">                                 $arg = isset($args[$matches[1]]) ? $args[$matches[1]] : '';
</span></span></pre></div>
<a id="trunkwpincludesfunctionsphp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/functions.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/functions.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/functions.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -2081,7 +2081,7 @@
</span><span class="cx">         if ( realpath($path) == $path )
</span><span class="cx">                 return true;
</span><span class="cx"> 
</span><del>-        if ( strlen($path) == 0 || $path{0} == '.' )
</del><ins>+        if ( strlen($path) == 0 || $path[0] == '.' )
</ins><span class="cx">                 return false;
</span><span class="cx"> 
</span><span class="cx">         // windows allows absolute paths like this
</span></span></pre></div>
<a id="trunkwpincludespluggablephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/pluggable.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/pluggable.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/pluggable.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -1658,7 +1658,7 @@
</span><span class="cx">                 $host = 'https://secure.gravatar.com';
</span><span class="cx">         } else {
</span><span class="cx">                 if ( !empty($email) )
</span><del>-                        $host = sprintf( &quot;http://%d.gravatar.com&quot;, ( hexdec( $email_hash{0} ) % 2 ) );
</del><ins>+                        $host = sprintf( &quot;http://%d.gravatar.com&quot;, ( hexdec( $email_hash[0] ) % 2 ) );
</ins><span class="cx">                 else
</span><span class="cx">                         $host = 'http://0.gravatar.com';
</span><span class="cx">         }
</span></span></pre></div>
<a id="trunkwpincludesposttemplatephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/post-template.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/post-template.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/post-template.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -727,7 +727,7 @@
</span><span class="cx">                 echo &quot;&lt;ul class='post-meta'&gt;\n&quot;;
</span><span class="cx">                 foreach ( (array) $keys as $key ) {
</span><span class="cx">                         $keyt = trim($key);
</span><del>-                        if ( '_' == $keyt{0} )
</del><ins>+                        if ( '_' == $keyt[0] )
</ins><span class="cx">                                 continue;
</span><span class="cx">                         $values = array_map('trim', get_post_custom_values($key));
</span><span class="cx">                         $value = implode($values,', ');
</span></span></pre></div>
<a id="trunkwpincludesrewritephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/rewrite.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/rewrite.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/rewrite.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -34,7 +34,7 @@
</span><span class="cx">  */
</span><span class="cx"> function add_rewrite_tag($tagname, $regex) {
</span><span class="cx">         //validation
</span><del>-        if ( strlen($tagname) &lt; 3 || $tagname{0} != '%' || $tagname{strlen($tagname)-1} != '%' )
</del><ins>+        if ( strlen($tagname) &lt; 3 || $tagname[0] != '%' || $tagname[strlen($tagname)-1] != '%' )
</ins><span class="cx">                 return;
</span><span class="cx"> 
</span><span class="cx">         $qv = trim($tagname, '%');
</span></span></pre></div>
<a id="trunkwpincludesthemephp"></a>
<div class="modfile"><h4>Modified: trunk/wp-includes/theme.php (16339 => 16340)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/wp-includes/theme.php        2010-11-13 09:45:57 UTC (rev 16339)
+++ trunk/wp-includes/theme.php        2010-11-13 09:53:55 UTC (rev 16340)
</span><span class="lines">@@ -597,7 +597,7 @@
</span><span class="cx"> 
</span><span class="cx">                 while ( ($theme_dir = readdir($themes_dir)) !== false ) {
</span><span class="cx">                         if ( is_dir($theme_root . '/' . $theme_dir) &amp;&amp; is_readable($theme_root . '/' . $theme_dir) ) {
</span><del>-                                if ( $theme_dir{0} == '.' || $theme_dir == 'CVS' )
</del><ins>+                                if ( $theme_dir[0] == '.' || $theme_dir == 'CVS' )
</ins><span class="cx">                                         continue;
</span><span class="cx"> 
</span><span class="cx">                                 $stylish_dir = @opendir($theme_root . '/' . $theme_dir);
</span><span class="lines">@@ -620,7 +620,7 @@
</span><span class="cx">                                         $found_subdir_themes = false;
</span><span class="cx">                                         while ( ($theme_subdir = readdir($theme_subdirs)) !== false ) {
</span><span class="cx">                                                 if ( is_dir( $subdir . '/' . $theme_subdir) &amp;&amp; is_readable($subdir . '/' . $theme_subdir) ) {
</span><del>-                                                        if ( $theme_subdir{0} == '.' || $theme_subdir == 'CVS' )
</del><ins>+                                                        if ( $theme_subdir[0] == '.' || $theme_subdir == 'CVS' )
</ins><span class="cx">                                                                 continue;
</span><span class="cx"> 
</span><span class="cx">                                                         $stylish_dir = @opendir($subdir . '/' . $theme_subdir);
</span></span></pre>
</div>
</div>

</body>
</html>