From 2c351a8bccdfe0fe9ad0ccb4dba5e15ef23b4c0c Mon Sep 17 00:00:00 2001 From: manuel Date: Wed, 13 Apr 2011 17:24:38 +0200 Subject: - rewrite network methods (ugly but good performance) - fix memleaks --- pacman-c++/client.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'pacman-c++/client.cpp') diff --git a/pacman-c++/client.cpp b/pacman-c++/client.cpp index 4843d95..5cc9279 100644 --- a/pacman-c++/client.cpp +++ b/pacman-c++/client.cpp @@ -67,6 +67,9 @@ bool Constants::server = false; int main(int argc, char ** argv) { + /* Verify that the version of the library that we linked against is + * compatible with the version of the headers we compiled against. + */ GOOGLE_PROTOBUF_VERIFY_VERSION; QApplication app(argc, argv, true); @@ -80,5 +83,10 @@ int main(int argc, char ** argv) client.show(); client.setWindowTitle(app.applicationName()); - return app.exec(); + int ret = app.exec(); + + /* Delete all global objects allocated by libprotobuf */ + google::protobuf::ShutdownProtobufLibrary(); + + return ret; } -- cgit v1.2.3