aboutsummaryrefslogtreecommitdiff
path: root/odb/mssql/connection.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-11-20 13:30:43 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-11-20 13:30:43 +0200
commit16283f61ddd0525b08e615fac6148f544973ac82 (patch)
tree04d2a2116ea9c6ee87bf441ca22df6e7f7e6572b /odb/mssql/connection.cxx
parent0362bba70741404fb5dca7f0bb7aa4c484f307cc (diff)
Handle error conditions that are indicated via return code
Diffstat (limited to 'odb/mssql/connection.cxx')
-rw-r--r--odb/mssql/connection.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/odb/mssql/connection.cxx b/odb/mssql/connection.cxx
index 50bc8db..788fecb 100644
--- a/odb/mssql/connection.cxx
+++ b/odb/mssql/connection.cxx
@@ -37,7 +37,7 @@ namespace odb
r = SQLAllocHandle (SQL_HANDLE_DBC, db_.environment (), &h);
if (!SQL_SUCCEEDED (r))
- translate_error (db_.environment (), SQL_HANDLE_ENV);
+ translate_error (r, db_.environment (), SQL_HANDLE_ENV);
handle_.reset (h);
}
@@ -59,7 +59,7 @@ namespace odb
// Still use the handle version of translate_error since there
// is no connection.
//
- translate_error (handle_, SQL_HANDLE_DBC);
+ translate_error (r, handle_, SQL_HANDLE_DBC);
state_ = state_connected;
}