Make sure status() returns a message also on bad connection
Closes #2173.
This commit is contained in:
parent
d58def6cdb
commit
749118cdee
1 changed files with 2 additions and 1 deletions
|
@ -127,7 +127,8 @@ public:
|
|||
std::string status;
|
||||
if (conn_)
|
||||
{
|
||||
status = PQerrorMessage(conn_);
|
||||
if ( isOK() ) return PQerrorMessage(conn_);
|
||||
else return "Bad connection";
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue