Closed themarpe closed 2 years ago
Good point - but I think that the scheduler still gets the event while event reader is busy looping and sets curr->resetXLink = 1; in XLinkDispatcher.c:1052 - didn't stumble upon XLink not closing down cleanly (eg eventReader continuing to busy loop), but haven't specifically tested for it as well. Will try creating a test now, by delaying the RESET_REQ event and timing out ASAP.
WRT the above - I've tested and it does busyloop until XLINK_RESET_REQ
arrives which then closes up scheduler and eventReader by setting `resetXLink = 1.
So same behavior as before with a eg. device unplug
Moved back to letting scheduler close down itself and only unblocking a blocked read/write in eventReader.
Deprecated XLinkGetFillLevel as its unsafe to call from external thread