Date: Wednesday, November 8, 2006 @ 11:51:48
  Author: csaba
    Path: /cvsroot/carob/libmysequoia/src

Modified: CarobMySQL.cpp (1.88 -> 1.89)

Do not call get_warning_count() if persistentConncetion is not set.


----------------+
 CarobMySQL.cpp |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)


Index: libmysequoia/src/CarobMySQL.cpp
diff -u libmysequoia/src/CarobMySQL.cpp:1.88 
libmysequoia/src/CarobMySQL.cpp:1.89
--- libmysequoia/src/CarobMySQL.cpp:1.88        Fri Oct 27 15:17:33 2006
+++ libmysequoia/src/CarobMySQL.cpp     Wed Nov  8 11:51:48 2006
@@ -373,7 +373,10 @@
         drsPtr = stmtPtr->getResultSet();
         mysqlPtr->field_count = drsPtr ? drsPtr->getNumberOfColumns() : 0;
         mysqlPtr->status = MYSQL_STATUS_GET_RESULT;
-        mysqlPtr->warning_count = get_warning_count();
+        if (usePersistentConnection)
+          mysqlPtr->warning_count = get_warning_count();
+        else
+          mysqlPtr->warning_count = 0;
 
         LOG4CXX_INFO(logger, "Executed query with result set. Field_count=" << 
mysqlPtr->field_count);
       }
@@ -382,7 +385,10 @@
         mysqlPtr->affected_rows = stmtPtr->getUpdateCount();
         mysqlPtr->status = MYSQL_STATUS_READY;
         mysqlPtr->field_count = 0;
-        mysqlPtr->warning_count = get_warning_count();
+        if (usePersistentConnection)
+          mysqlPtr->warning_count = get_warning_count();
+        else
+          mysqlPtr->warning_count = 0;
         
         char info[100];
         snprintf(info, sizeof(info), "Records: %llu  Duplicates: 0  Warnings: 
%u", mysqlPtr->affected_rows, mysqlPtr->warning_count);

_______________________________________________
Carob-commits mailing list
[email protected]
https://forge.continuent.org/mailman/listinfo/carob-commits

Reply via email to