Re: How much is available for reading on the socket?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Em Fri, Nov 09, 2007 at 01:51:27PM +0000, Gerrit Renker escreveu:
> | > using "ioctl (socket, FIONREAD, &readsize)" I can get how much is
> | > available to read from the socket using TCP. Is there a equivalent
> | > option for DCCP?
> | 
> | Looks like dccp_ioctl() happily returns -ENOIOCTLCMD (for now). If you
> | have IO and memory to waste, you can always recv(..., MSG_PEEK) to work
> | around this.
> | 
> Arnaldo wrote a patch which realises SIOCINQ (it is in 2.6.24-rc1/2).

And, on Linux:

include/linux/sockios.h

/* Linux-specific socket ioctls */
#define SIOCINQ         FIONREAD

- Arnaldo
-
To unsubscribe from this list: send the line "unsubscribe dccp" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel]     [IETF DCCP]     [Linux Networking]     [Git]     [Security]     [Linux Assembly]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux