Log Message:
-----------
fix server menu after failed connect
Modified Files:
--------------
pgadmin3/src/ui:
frmMain.cpp (r1.113 -> r1.114)
Index: frmMain.cpp
===================================================================
RCS file: /projects/pgadmin3/src/ui/frmMain.cpp,v
retrieving revision 1.113
retrieving revision 1.114
diff -Lsrc/ui/frmMain.cpp -Lsrc/ui/frmMain.cpp -u -w -r1.113 -r1.114
--- src/ui/frmMain.cpp
+++ src/ui/frmMain.cpp
@@no-spam -703,6 +703,7 @@no-spam
switch (res)
{
case PGCONN_OK:
+ {
StartMsg(_("Restoring previous environment"));
wxLogInfo(wxT("pgServer object initialised as required."));
browser->SetItemImage(server->GetId(), PGICON_SERVER, wxTreeItemIcon_Normal);
@@no-spam -722,7 +723,8 @@no-spam
browser->EnsureVisible(item);
}
EndMsg();
- break;
+ return res;
+ }
case PGCONN_DNSERR:
/*
// looks strange to me. Shouldn_t server be removed from the tree as well?
@@no-spam -737,6 +739,8 @@no-spam
wxLogInfo(wxT("pgServer object didn't initialise because the user aborted."));
break;
}
+
+ server->Disconnect();
return res;
}
[plaintext cvs-20041216114745-diff.txt]
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?
http://archives.postgresql.org