summaryrefslogtreecommitdiff
path: root/node/EthernetTap.cpp
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2013-08-05 16:06:16 -0400
committerAdam Ierymenko <adam.ierymenko@gmail.com>2013-08-05 16:06:16 -0400
commita7c4cbe53aad51b3e74fa9cb1af975cb8d356954 (patch)
treee4578c51ea7239aeaf5dd6ebcaa844a0fb00f9ea /node/EthernetTap.cpp
parent3368330b777da9561539c04ea589aa7060e1d569 (diff)
downloadinfinitytier-a7c4cbe53aad51b3e74fa9cb1af975cb8d356954.tar.gz
infinitytier-a7c4cbe53aad51b3e74fa9cb1af975cb8d356954.zip
CLI debugging, got rid of nasty old Thread class and replaced with newer cleaner portable idiom.
Diffstat (limited to 'node/EthernetTap.cpp')
-rw-r--r--node/EthernetTap.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/node/EthernetTap.cpp b/node/EthernetTap.cpp
index c45d50c2..870baceb 100644
--- a/node/EthernetTap.cpp
+++ b/node/EthernetTap.cpp
@@ -187,7 +187,7 @@ EthernetTap::EthernetTap(
TRACE("tap %s created",_dev);
- start();
+ _thread = Thread<EthernetTap>::start(this);
}
#endif // __LINUX__
@@ -271,14 +271,14 @@ EthernetTap::EthernetTap(
::pipe(_shutdownSignalPipe);
- start();
+ _thread = Thread<EthernetTap>::start(this);
}
#endif // __APPLE__
EthernetTap::~EthernetTap()
{
::write(_shutdownSignalPipe[1],"\0",1); // causes thread to exit
- join();
+ Thread<EthernetTap>::join(_thread);
::close(_fd);
}
@@ -549,7 +549,7 @@ bool EthernetTap::updateMulticastGroups(std::set<MulticastGroup> &groups)
}
#endif // __APPLE__
-void EthernetTap::main()
+void EthernetTap::threadMain()
throw()
{
fd_set readfds,nullfds;