lkml.org 
[lkml]   [1998]   [Oct]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: apropos recvfrom
From
Date
In article <Pine.LNX.3.96.981015214337.6013A-100000@apemaia.roma1.infn.it>,
Davide Rossetti <rossetti@apemaia.roma1.infn.it> writes:
> hi all,
> On Linux 2.1.125 (not sure, but also on 2.0.35)
> I beg your pardon for my silliness. Now I got a strange result.
> 1) client side:
> sendmsg() with
> msg_iov = array of 3 iovec
> msg_iovlen= 3
> it returns 3 !!!

> 2) server side:
> recvmsg() with
> msg_iov = array of 2 iovec
> msg_iovlen = 2
> it returns 3 !!! (msg_flags==0)

> browsing http://www.opengroup.org/onlinepubs/7908799/xns/recvmsg.html,
> it seems that both functions should return the total recvd/sent bytes.
> Am I wrong ?
> In case I am, how can I get the exact fill status of my recvd iovecs,
> that is, how many bytes got received ?

You do. The result means that the datagram only carried 3 bytes of payload.
How you map that to your iovs is a user space problem.


-Andi


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:45    [W:0.023 / U:1.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site