From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
To: linux-sctp@vger.kernel.org
Subject: Re: SCTP recvmsg MSG_TRUNC or something similar
Date: Thu, 25 Jul 2019 01:21:15 +0000 [thread overview]
Message-ID: <20190725012115.GA4064@localhost.localdomain> (raw)
In-Reply-To: <D588EC18-6A7B-4D2B-AB0A-2961A247DC3B@cnix.ro>
On Wed, Jul 24, 2019 at 02:46:09PM +0100, Luci Stanescu wrote:
> Hi,
Hi,
>
> I’m not sure this is the right place to ask this kind of question,
> but, having not found a better forum, I’m trying my luck. Apologies
Considering you're programming for Linux, it is. :-)
> in advance if this is outside the scope of the mailing list.
>
> That being said, my question is: given a successful return of
> recvmsg() for a SOCK_SEQPACKET SCTP socket, is there no stateless
> way to determine if the read data, for which the MSG_EOR flag is
> set, is the trailing “fragment” of a larger record (either due to
> partial delivery or an insufficient buffer passed to a prior call to
> recvmsg() which returned with the MSG_EOR flag cleared), rather than
> a “full” message?
Stateless, I'm not aware of a way.
We do have SCTP_PARTIAL_DELIVERY_EVENT, though, and RCVINFO. But these
would require some state to be preserved.
MSG_PEEK also, but also requires some state.
>
> From what I can tell, MSG_TRUNC, which would’ve solved my issue,
> isn’t implemented for SCTP. Regarding this topic, I’ve only found
Agreed, but MSG_TRUNC would cause information loss.
What about using a larger buf?
> old discussions, including some suggestions to add SOCK_RDM, which
> never materialised.
>
> Many thanks for your time!
>
> Luci
Regards,
Marcelo
next prev parent reply other threads:[~2019-07-25 1:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-24 13:46 SCTP recvmsg MSG_TRUNC or something similar Luci Stanescu
2019-07-25 1:21 ` Marcelo Ricardo Leitner [this message]
2019-07-25 9:53 ` Luci Stanescu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190725012115.GA4064@localhost.localdomain \
--to=marcelo.leitner@gmail.com \
--cc=linux-sctp@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.