#At bzr+ssh://bk-internal.mysql.com/bzrroot/mysql-falcon/
194 Hakan Kuecuekyilmaz 2008-05-27
str_ireplace() is supported by PHP >= 5, but production.mysql.com
is running PHP 4.3.x. Therefore reverting back to str_replace().
modified:
dbt2/include/sample_cpu_data.php
=== modified file 'dbt2/include/sample_cpu_data.php'
--- a/dbt2/include/sample_cpu_data.php 2008-05-20 14:21:06 +0000
+++ b/dbt2/include/sample_cpu_data.php 2008-05-27 20:44:22 +0000
@@ -51,8 +51,8 @@
$arr = file($directory . '/' . $file_name);
foreach($arr as $line) {
if (preg_match($pattern, $line)) {
- $line = str_ireplace('AM', '', $line);
- $line = str_ireplace('PM', '', $line);
+ $line = str_replace('AM', '', $line);
+ $line = str_replace('PM', '', $line);
$temp = preg_split('|[\s]+|', $line);
if ($temp[1] == 'CPU') {
@@ -83,8 +83,8 @@
$io = 0;
foreach($arr as $line) {
if (preg_match($pattern, $line)) {
- $line = str_ireplace('AM', '', $line);
- $line = str_ireplace('PM', '', $line);
+ $line = str_replace('AM', '', $line);
+ $line = str_replace('PM', '', $line);
$temp = preg_split('|[\s]+|', $line);
// Determine position of user/system/iowait.
| Thread |
|---|
| • commit into MySQL/Falcon helper scripts, tests,and programs:mysql-falcon branch (hakan:194) | Hakan Kuecuekyilmaz | 27 May |