summaryrefslogtreecommitdiff
path: root/node/Network.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@zerotier.com>2013-08-27 18:00:07 -0400
committerAdam Ierymenko <adam.ierymenko@zerotier.com>2013-08-27 18:00:07 -0400
commit01a70d09db917ce475120854514ee48af43cc1b1 (patch)
treebef52e0bac273766396062d87dd6d3d491911e42 /node/Network.cpp
parent0afcf4877c9694a517a5bf62b604387eb2099aba (diff)
downloadinfinitytier-01a70d09db917ce475120854514ee48af43cc1b1.tar.gz
infinitytier-01a70d09db917ce475120854514ee48af43cc1b1.zip
Jigger with shutdown method to avoid a crash on CTRL+C in Windows. Feels a big hacky, might revisit later.
Diffstat (limited to 'node/Network.cpp')
-rw-r--r--node/Network.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/node/Network.cpp b/node/Network.cpp
index 730e86d2..1e436a27 100644
--- a/node/Network.cpp
+++ b/node/Network.cpp
@@ -282,6 +282,8 @@ void Network::_CBhandleTapData(void *arg,const MAC &from,const MAC &to,unsigned
if (!((Network *)arg)->_ready)
return;
const RuntimeEnvironment *_r = ((Network *)arg)->_r;
+ if (_r->shutdownInProgress)
+ return;
try {
_r->sw->onLocalEthernet(SharedPtr<Network>((Network *)arg),from,to,etherType,data);
} catch (std::exception &exc) {