diff Core/SQLite/StatementReference.cpp @ 657:5425bb6f1ea5

further cppcheck fixes
author Sebastien Jodogne <s.jodogne@gmail.com>
date Mon, 04 Nov 2013 11:46:23 +0100
parents 08eca5d86aad
children 2d0a347e8cfc
line wrap: on
line diff
--- a/Core/SQLite/StatementReference.cpp	Mon Nov 04 11:19:31 2013 +0100
+++ b/Core/SQLite/StatementReference.cpp	Mon Nov 04 11:46:23 2013 +0100
@@ -119,7 +119,11 @@
       {
         if (root_->refCount_ == 0)
         {
-          throw OrthancException(ErrorCode_InternalError);
+          // There remain references to this object. We cannot throw
+          // an exception because:
+          // http://www.parashift.com/c++-faq/dtors-shouldnt-throw.html
+
+          LOG(ERROR) << "Bad value of the reference counter";
         }
         else
         {