From 15148413453ae173d32f00c8c69a86731d43e70d Mon Sep 17 00:00:00 2001
From: dmartinez <dmartinez@iri.upc.edu>
Date: Fri, 14 Feb 2014 19:47:08 +0100
Subject: [PATCH] Fixed some problems with automatic port selection.

---
 src/ippc_wrapper/ippc_planner.cpp | 2 +-
 src/symbolic/utils.cpp            | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/ippc_wrapper/ippc_planner.cpp b/src/ippc_wrapper/ippc_planner.cpp
index 85529cfe..880aafa7 100755
--- a/src/ippc_wrapper/ippc_planner.cpp
+++ b/src/ippc_wrapper/ippc_planner.cpp
@@ -12,7 +12,7 @@ IppcPlanner::IppcPlanner(const ConfigReader& config_reader)
     planner_path = config_reader.get_path("planner_path");
     planner_port = config_reader.get_variable<uint>("planner_port");
     if (planner_port == 0) { // auto selection
-        planner_port = utils::get_socket_from_current_dir_hash() + 1;
+        planner_port = utils::get_socket_from_current_dir_hash() + 5000;
     }
 //     ippcserver.start_session();
 //     ippcserver.start_round();
diff --git a/src/symbolic/utils.cpp b/src/symbolic/utils.cpp
index da7aa8be..e3b4e81a 100644
--- a/src/symbolic/utils.cpp
+++ b/src/symbolic/utils.cpp
@@ -5,7 +5,7 @@ uint utils::get_socket_from_current_dir_hash()
 {
     boost::filesystem::path full_path = boost::filesystem::current_path();
     boost::hash<std::string> string_hash;
-    return (string_hash(full_path.generic_string()) % 10000000) + 10000; // [10.000, 10.010.000]
+    return (string_hash(full_path.generic_string()) % 10000000) + 20000; // [10.000, 10.010.000]
 }
     
 
-- 
GitLab