Log Message:
-----------
Added .c_str()'s I missed first time round.
Need unistd.h for gethostname() on *nix

Modified Files:
--------------
    pgadmin3/src/ui:
        frmMain.cpp (r1.99 -> r1.100)

Index: frmMain.cpp
===================================================================
RCS file: /projects/pgadmin3/src/ui/frmMain.cpp,v
retrieving revision 1.99
retrieving revision 1.100
diff -Lsrc/ui/frmMain.cpp -Lsrc/ui/frmMain.cpp -u -w -r1.99 -r1.100
--- src/ui/frmMain.cpp
+++ src/ui/frmMain.cpp
@@ -14,6 +14,10 @@
 
 #include "pgAdmin3.h"
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 // wxWindows headers
 #include <wx/wx.h>
 #include <wx/splitter.h>
@@ -821,39 +825,39 @@
 
                                // This is a discovered server...
                                // Hostname
-                               key.Printf(wxT("Servers/Server-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Server-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, server->GetName());
 
                                // Comment
-                               key.Printf(wxT("Servers/Description-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Description-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, server->GetDescription());
 
                                // Port
-                               key.Printf(wxT("Servers/Port-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Port-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, server->GetPort());
 
                                // Trusted
-                               key.Printf(wxT("Servers/Trusted-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Trusted-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, BoolToStr(server->GetTrusted()));
 
                                // Database
-                               key.Printf(wxT("Servers/Database-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Database-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, server->GetDatabaseName());
 
                                // Username
-                               key.Printf(wxT("Servers/Username-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/Username-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                        settings->Write(key, server->GetUsername());
 
                                // SSL
-                               key.Printf(wxT("Servers/SSL-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/SSL-%s-%s"), hostname.c_str(), 
server->GetServiceID().c_str());
                        settings->Write(key, server->GetSSL());
 
                                // Last Database
-                               key.Printf(wxT("Servers/LastDatabase-%s-%s"), 
hostname, server->GetServiceID());
+                               key.Printf(wxT("Servers/LastDatabase-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                                settings->Write(key, server->GetLastDatabase());
        
                                // Last Schema
-                               key.Printf(wxT("Servers/LastSchema-%s-%s"), hostname, 
server->GetServiceID());
+                               key.Printf(wxT("Servers/LastSchema-%s-%s"), 
hostname.c_str(), server->GetServiceID().c_str());
                                settings->Write(key, server->GetLastSchema());
                        }
                }
---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
      subscribe-nomail command to [EMAIL PROTECTED] so that your
      message can get through to the mailing list cleanly

Reply via email to