Socket vs File descriptor

From: KV Pavuram
Date: Thu Sep 24 2009 - 02:58:13 EST


Hi,

Is there any ioctl call to determine if a given descriptor is a file descriptor or a socket descriptor.

Similarly, is there a way to find out a socket descriptor type ie.e if it is SOCK_STREAM, or SOCK_DGRAM type.

Thanks
Pav


See the Web's breaking stories, chosen by people like you. Check out Yahoo! Buzz. http://in.buzz.yahoo.com/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/