fix: MXL_ERR_FLOW_INVALID reconnect, nullptr→"" options, null guards

Readers (ndiout, fakesink) now handle MXL_ERR_FLOW_INVALID by releasing
and recreating the flow reader, then realigning the index to current time.
This lets consumer nodes survive a producer restart without exiting.

All mxlCreateInstance/FlowWriter/FlowReader options args changed from
nullptr to "" to match MXL reference implementation style.

mxlReleaseFlowReader calls guarded with null checks so cleanup is safe
when a mid-run reconnect attempt fails.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
JohannesItten
2026-07-03 10:28:30 +03:00
parent 21a8ee4ba0
commit f2515b7ce2
6 changed files with 45 additions and 13 deletions
+1 -1
View File
@@ -155,7 +155,7 @@ int main(int argc, char* argv[]) {
// Clean up stale flow directories left by any previous crashed run
{
mxlInstance gc = mxlCreateInstance(domain.c_str(), nullptr);
mxlInstance gc = mxlCreateInstance(domain.c_str(), "");
if (gc) {
mxlGarbageCollectFlows(gc);
mxlDestroyInstance(gc);