We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b613d56 commit 1ae223bCopy full SHA for 1ae223b
src/zm_event.cpp
@@ -697,7 +697,6 @@ void Event::Run() {
697
std::this_thread::sleep_for(sleep_for);
698
continue;
699
}
700
- packetqueue->increment_it(packetqueue_it);
701
702
Debug(1, "Adding packet %d", packet->image_index);
703
this->AddPacket_(packet);
@@ -719,6 +718,8 @@ void Event::Run() {
719
718
} // end if packet->image
720
Debug(1, "Deleting packet lock");
721
delete packet_lock;
+ // Important not to increment it until after we are done with the packet because clearPackets checks for iterators pointing to it.
722
+ packetqueue->increment_it(packetqueue_it);
723
} else {
724
return;
725
} // end if packet_lock
0 commit comments