set jurisdiction listener object name for thread identification

This commit is contained in:
Stephen Birarda 2015-07-15 18:52:59 -07:00
parent 6fa17dafff
commit 039ef0750c
2 changed files with 3 additions and 2 deletions

View file

@ -39,7 +39,6 @@ bool ReceivedPacketProcessor::process() {
quint64 now = usecTimestampNow();
quint64 sinceLastWindow = now - _lastWindowAt;
if (sinceLastWindow > USECS_PER_SECOND) {
lock();
float secondsSinceLastWindow = sinceLastWindow / USECS_PER_SECOND;

View file

@ -20,6 +20,8 @@ JurisdictionListener::JurisdictionListener(NodeType_t type) :
_nodeType(type),
_packetSender(JurisdictionListener::DEFAULT_PACKETS_PER_SECOND)
{
setObjectName("Jurisdiction Listener");
connect(DependencyManager::get<NodeList>().data(), &NodeList::nodeKilled, this, &JurisdictionListener::nodeKilled);
// tell our NodeList we want to hear about nodes with our node type
@ -34,7 +36,7 @@ void JurisdictionListener::nodeKilled(SharedNodePointer node) {
bool JurisdictionListener::queueJurisdictionRequest() {
auto packet = NLPacket::create(PacketType::JurisdictionRequest, 0);
auto nodeList = DependencyManager::get<NodeList>();
int nodeCount = 0;