summaryrefslogtreecommitdiffstats
path: root/system/database
diff options
context:
space:
mode:
authorKatsumi Honda <k@qox.jp>2013-03-19 09:56:09 +0100
committerKatsumi Honda <k@qox.jp>2013-03-19 09:56:09 +0100
commiteaeaad5e974223d814ad7e0fa01d1923dc3c571a (patch)
treee576c87a9a2bf75096fe084b0e16a855716dc77f /system/database
parent13f6eabafa655828a8c09b4ae0a58a2e3776c269 (diff)
Fixed problem for transaction test mode.
trans_complete function is committed in test mode. Because any database drivers are set _trans_failure in test_mode, And trans_complete function is not evaluate _trans_failure.
Diffstat (limited to 'system/database')
-rw-r--r--system/database/DB_driver.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/system/database/DB_driver.php b/system/database/DB_driver.php
index 18dbbc76e..3e6378448 100644
--- a/system/database/DB_driver.php
+++ b/system/database/DB_driver.php
@@ -816,7 +816,7 @@ abstract class CI_DB_driver {
}
// The query() function will set this flag to FALSE in the event that a query failed
- if ($this->_trans_status === FALSE)
+ if ($this->_trans_status === FALSE || $this->_trans_failure === TRUE)
{
$this->trans_rollback();
@@ -1859,4 +1859,4 @@ abstract class CI_DB_driver {
}
/* End of file DB_driver.php */
-/* Location: ./system/database/DB_driver.php */ \ No newline at end of file
+/* Location: ./system/database/DB_driver.php */