summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <remko@synopsys.com>2011-09-30 17:10:20 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-09-30 17:15:59 (GMT)
commit75818abb4baa26649baf8d3bf6709aefcda7195f (patch)
tree25cf8cc224100688d813ab57f3ccf32771f1bdf1 /Swiften/Examples/NetworkTool
parenta98f648f5cfbf474c566bd63193047e5381e7d5e (diff)
downloadswift-contrib-75818abb4baa26649baf8d3bf6709aefcda7195f.zip
swift-contrib-75818abb4baa26649baf8d3bf6709aefcda7195f.tar.bz2
Fixed some Windows issues with FT.
Diffstat (limited to 'Swiften/Examples/NetworkTool')
-rw-r--r--Swiften/Examples/NetworkTool/main.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/Swiften/Examples/NetworkTool/main.cpp b/Swiften/Examples/NetworkTool/main.cpp
index fa19e14..ace38fd 100644
--- a/Swiften/Examples/NetworkTool/main.cpp
+++ b/Swiften/Examples/NetworkTool/main.cpp
@@ -12,6 +12,7 @@
#include <Swiften/Network/NATTraversalGetPublicIPRequest.h>
#include <Swiften/Network/NATTraversalForwardPortRequest.h>
#include <Swiften/Network/NATTraversalRemovePortForwardingRequest.h>
+#include <Swiften/Network/PlatformNetworkEnvironment.h>
using namespace Swift;
@@ -78,4 +79,7 @@ int main(int argc, char* argv[]) {
query->run();
eventLoop.run();
}
+ else if (std::string(argv[1]) == "get-local-ip") {
+ std::cout << PlatformNetworkEnvironment().getLocalAddress().toString() << std::endl;
+ }
}