Skip to content
This repository was archived by the owner on Jul 8, 2022. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions cppapi/server/pipe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,12 @@ void Pipe::fire_event(DeviceImpl *dev,DevicePipeBlob *p_data,struct timeval &t,b
delta_subscription = now - event_subscription;

if (delta_subscription >= EVENT_RESUBSCRIBE_PERIOD)
{
p_data->reset_insert_ctr();
DevVarPipeDataEltArray *tmp_ptr = p_data->get_insert_data();
delete tmp_ptr;
return;
}

//
// Get the event supplier, and simply return if not created
Expand All @@ -801,6 +806,9 @@ void Pipe::fire_event(DeviceImpl *dev,DevicePipeBlob *p_data,struct timeval &t,b

if (event_supplier_zmq == NULL)
{
p_data->reset_insert_ctr();
DevVarPipeDataEltArray *tmp_ptr = p_data->get_insert_data();
delete tmp_ptr;
return;
}

Expand Down