summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2017-01-03 16:42:26 +0100
committerAndrey Andreev <narf@devilix.net>2017-01-03 16:42:26 +0100
commit51c84f3a436ecfebe371177ba5537b9e475cc3c6 (patch)
tree27b55160e80c980130fd48d767da0acfdfd01f59
parent973dbfc648705b26234d5100c08625af8e1a34d6 (diff)
Fix #4804
-rw-r--r--system/database/DB_query_builder.php2
-rw-r--r--user_guide_src/source/changelog.rst1
2 files changed, 2 insertions, 1 deletions
diff --git a/system/database/DB_query_builder.php b/system/database/DB_query_builder.php
index 3f1a8021a..ab19d97a2 100644
--- a/system/database/DB_query_builder.php
+++ b/system/database/DB_query_builder.php
@@ -1553,7 +1553,7 @@ abstract class CI_DB_query_builder extends CI_DB_driver {
is_bool($escape) OR $escape = $this->_protect_identifiers;
- $keys = array_keys($this->_object_to_array(current($key)));
+ $keys = array_keys($this->_object_to_array(reset($key)));
sort($keys);
foreach ($key as $row)
diff --git a/user_guide_src/source/changelog.rst b/user_guide_src/source/changelog.rst
index ac245c998..73a0232be 100644
--- a/user_guide_src/source/changelog.rst
+++ b/user_guide_src/source/changelog.rst
@@ -33,6 +33,7 @@ Bug fixes for 3.1.3
- Fixed a regression (#4892) - :doc:`Query Builder <database/query_builder>` method ``update_batch()`` didn't properly handle identifier escaping.
- Fixed a bug (#4953) - :doc:`Database Forge <database/forge>` method ``create_table()`` didn't update an internal tables list cache if it exists but is empty.
- Fixed a bug (#4958) - :doc:`Query Builder <database/query_builder>` method ``count_all_results()`` didn't take into account cached ``ORDER BY`` clauses.
+- Fixed a bug (#4804) - :doc:`Query Builder <database/query_builder>` method ``insert_batch()`` would skip input data elements if the input array pointer was modified on PHP 7+.
Version 3.1.2
=============