You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
According to the docs, when a connection has been made in file/message mode, srt_recv should return SRT_ERROR and set SRT_ELARGEMSG when a message will not entirely fit in the provided buffer.
To Reproduce
Steps to reproduce the behavior:
Create connection in file/message mode.
Send large message to receiver
Call srt_recv with a buffer too small to contain the entire message.
Verify SRT_ERROR is not returned.
Expected behavior SRT_ERROR should be returned and SRT_ELARGEMSG should be returned from srt_getlasterror.
Additional context
Additionally, the table entry for SRT_ELARGEMSG under srt_recv mentions the sending buffer, although that's not relevant for receiving.
The text was updated successfully, but these errors were encountered:
This is only mentioned by the description of SRT_ELARGEMSG, but nothing like this is mentioned by the srt_recvmsg description
The description for SRT_ELARGEMSG is mentioned by srt_recvmsg, but it is likely copied from the one for srt_sendmsg as the text is identical and doesn't make any sense there
The current state is kinda unstable, even if it is consistent with system UDP approach (and likely also used in SCTP), but also not perfectly - UDP/SCTP use recvmsg function to receive the message and when the buffer is too small, the MSG_TRUNC is set on the flags on return. A similar thing could be also implemented for srt_recvmsg2 for consistency.
Describe the bug
According to the docs, when a connection has been made in file/message mode,
srt_recv
should returnSRT_ERROR
and setSRT_ELARGEMSG
when a message will not entirely fit in the provided buffer.To Reproduce
Steps to reproduce the behavior:
srt_recv
with a buffer too small to contain the entire message.SRT_ERROR
is not returned.Expected behavior
SRT_ERROR
should be returned andSRT_ELARGEMSG
should be returned fromsrt_getlasterror
.Additional context
Additionally, the table entry for
SRT_ELARGEMSG
undersrt_recv
mentions the sending buffer, although that's not relevant for receiving.The text was updated successfully, but these errors were encountered: