Subject: sctp_recvmsg() vs recvmsg()

From: Salvatore Loreto <[email-masked]>
Date: Sun, 24 Jul 2005 18:05:43 +0200 (CEST)

Hi all,

I've a doubt about the difference (if there are)
between sctp_recvmsg() and recvmsg()

in sctp_recvmsg I can specify the length of message
buffer, so I can divide the message reception in more
steps. Isn't it ?

I think it is possible to do the same also with
recvmsg, I can specify in the field of struct iovec
the lenght of message buffer.
If I do this, do I have the same behaviour?

thank you in advance
/sal

		
___________________________________ 
Yahoo! Mail: gratis 1GB per i messaggi e allegati da 10MB 
http://mail.yahoo.it

---

From: Michael Tuexen <[email-masked]>
Date: Sun, 24 Jul 2005 20:01:54 +0200

Hi Sal,

sctp_recvmsg is only a more convient way to access SCTP functionality
available via recvmsg. In some implementations sctp_recvmsg is
implemented via a recvmsg call.

Best regards
Michael

---

From: Randall Stewart <[email-masked]>
Date: Mon, 25 Jul 2005 07:06:37 -0400

> implemented via a recvmsg call.

What he said :-D

Bascially, it hides the ugly CMSG stuff from you in SOME
implementations.. however others implementations MIGHT
develop a true system call to do this ( I plan on
doing this for FreeBSD eventually... this is because
all that CMSG stuff takes a lot of extra CPU and
if I do it in a system call it will increase performance)

R

-- 
Randall Stewart
ITD - Cisco Systems Inc.
803-345-0369 <or> 815-342-5222 (cell)

---

From: Salvatore Loreto <[email-masked]>
Date: Mon, 25 Jul 2005 13:29:59 +0200 (CEST)

ok

but the basic question is 
what happens if I specify a very short length of
message buffer?

thank you
Sal

		
___________________________________ 
Yahoo! Messenger: chiamate gratuite in tutto il mondo 
http://it.beta.messenger.yahoo.com

---

From: "Anatoly Khusid" <[email-masked]>
Date: Mon, 25 Jul 2005 07:47:16 -0400

Then MSG_EOR bit will not be set in msg_flags.

-----Original Message-----
From: Salvatore Loreto [mailto:[email-masked]]
Sent: Monday, July 25, 2005 7:30 AM
To: Randall Stewart
Cc: Michael Tuexen; [email-masked];
[email-masked]
Subject: Re: sctp_recvmsg() vs recvmsg()

ok

thank you
Sal

---

From: Randall Stewart <[email-masked]>
Date: Mon, 25 Jul 2005 10:38:39 -0400

Depends ..

What socket options are set...

You could get a

MSG_TRUNC

or you could get the rest of
it in the next read.

R

Salvatore Loreto wrote:
>>>sctp_recvmsg is only a more convient way to access
>>
>>SCTP functionality
>>
>>>available via recvmsg. In some implementations
>>
>>sctp_recvmsg is
>>
>>>On Jul 24, 2005, at 18:05 Uhr, Salvatore Loreto
>>
>>wrote:
>>
>>>>Hi all,
>>>>
>>>>in sctp_recvmsg I can specify the length of
>>
>>message
>>
>>>>buffer, so I can divide the message reception in
>>
>>more
>>
>>>>steps. Isn't it ?
>>>>
>>>>recvmsg, I can specify in the field of struct
>>
>>iovec
>>
>>>>Yahoo! Mail: gratis 1GB per i messaggi e allegati
>>
>>da 10MB
>>
>>>>http://mail.yahoo.it
>>>
>>>
>>>
>>
>>-- 
>>Randall Stewart
>>ITD - Cisco Systems Inc.