summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDerek Jones <derek.jones@ellislab.com>2008-01-18 16:52:48 +0100
committerDerek Jones <derek.jones@ellislab.com>2008-01-18 16:52:48 +0100
commit8435771a6f831fece5d4267e97c5e9c361dcb70b (patch)
treee7469b569de52446690bdecb5e5e164935f87faa
parent8f00021b55a87ec64a50d15f765160bd4e908c6b (diff)
fixed bug #3260 tightened type checking before outputting MySQL field as NULL
-rw-r--r--system/database/drivers/mysql/mysql_utility.php2
-rw-r--r--system/database/drivers/mysqli/mysqli_utility.php2
-rw-r--r--user_guide/changelog.html1
3 files changed, 3 insertions, 2 deletions
diff --git a/system/database/drivers/mysql/mysql_utility.php b/system/database/drivers/mysql/mysql_utility.php
index c24a008fa..3c5b94013 100644
--- a/system/database/drivers/mysql/mysql_utility.php
+++ b/system/database/drivers/mysql/mysql_utility.php
@@ -179,7 +179,7 @@ class CI_DB_mysql_utility extends CI_DB_utility {
$v = str_replace('\\\t', '\t', $v);
// Is the value NULL?
- if ($v == NULL)
+ if ($v === NULL)
{
$val_str .= 'NULL';
}
diff --git a/system/database/drivers/mysqli/mysqli_utility.php b/system/database/drivers/mysqli/mysqli_utility.php
index 1d910638f..3c9094611 100644
--- a/system/database/drivers/mysqli/mysqli_utility.php
+++ b/system/database/drivers/mysqli/mysqli_utility.php
@@ -180,7 +180,7 @@ class CI_DB_mysqli_utility extends CI_DB_utility {
$v = str_replace('\\\t', '\t', $v);
// Is the value NULL?
- if ($v == NULL)
+ if ($v === NULL)
{
$val_str .= 'NULL';
}
diff --git a/user_guide/changelog.html b/user_guide/changelog.html
index 89276e246..c516a4cd6 100644
--- a/user_guide/changelog.html
+++ b/user_guide/changelog.html
@@ -125,6 +125,7 @@ Change Log
<li>Fixed a bug in the typography helper causing extraneous paragraph tags when string contains tags.</li>
<li>Fixed a bug in the Encryption Library to support modes other than MCRYPT_MODE_ECB</li>
<li>Fixed a bug (#3175) preventing certain libraries from working properly when autoloaded in PHP 4</li>
+ <li>Fixed a bug (#3260) in MySQL backup utility where variables with loose type equivalents to NULL would be output as MySQL NULL.</li>
<li>Fixed an example of comma-separated emails in the email library documentation.</li>
<li>Fixed an example in the Calendar library for Showing Next/Previous Month Links.</li>
<li>Fixed a typo in the database language file.</li>