improved error handling on msg desync on TTY connections.

just directly flush on error and return to normal operations immediately.
This commit is contained in:
Martin Preuss
2026-05-04 10:25:29 +02:00
parent 47cd79d7aa
commit 7f28c22f6a

View File

@@ -248,11 +248,19 @@ void AQH_MsgReader_StartSkipping(AQH_OBJECT *o)
xo=GWEN_INHERIT_GETDATA(AQH_OBJECT, AQH_MSG_READER, o);
if (xo) {
int rv;
DBG_ERROR(AQH_LOGDOMAIN, "Enter skip mode");
GWEN_RingBuffer_Reset(xo->ringBuffer);
_resetBuffers(xo);
xo->flags|=AQH_MSGREADER_FLAGS_SKIP;
xo->timestamp=_getTimeInMilliSeconds();
rv=AQH_FdObject_FlushInput(xo->fdObject);
if (rv<0) {
AQH_Object_EmitSignal(o, AQH_MSG_READER_SIGNAL_ERROR, rv, NULL);
}
//xo->flags|=AQH_MSGREADER_FLAGS_SKIP;
//xo->timestamp=_getTimeInMilliSeconds();
}
}