From 2cc50bdb10c0a7849763ae1dfa37ca7707299a16 Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Mon, 9 Nov 2015 15:44:13 -0800 Subject: Try bringing back TTL escalation -- may help with Docker (IP-MASQ) type NAT --- node/Node.hpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'node/Node.hpp') diff --git a/node/Node.hpp b/node/Node.hpp index 76dec50e..15295139 100644 --- a/node/Node.hpp +++ b/node/Node.hpp @@ -149,9 +149,10 @@ public: * @param addr Destination address * @param data Packet data * @param len Packet length + * @param ttl Desired TTL (default: 0 for unchanged/default TTL) * @return True if packet appears to have been sent */ - inline bool putPacket(const InetAddress &localAddress,const InetAddress &addr,const void *data,unsigned int len) + inline bool putPacket(const InetAddress &localAddress,const InetAddress &addr,const void *data,unsigned int len,unsigned int ttl = 0) { return (_wirePacketSendFunction( reinterpret_cast(this), @@ -159,7 +160,8 @@ public: reinterpret_cast(&localAddress), reinterpret_cast(&addr), data, - len) == 0); + len, + ttl) == 0); } /** -- cgit v1.2.3