summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Graf <tgraf@redhat.com>2012-11-06 00:19:28 +0100
committerThomas Graf <tgraf@redhat.com>2012-11-06 00:19:28 +0100
commitceb8fb9e8747dd21f4067720e1090384910d348b (patch)
tree0a9c2cb5a0a863d0d35fcfdae836f1f887fd7883
parentbc7c822f54ac2b22d0d6595ca756464cf087c3a1 (diff)
downloadlibnl-ceb8fb9e8747dd21f4067720e1090384910d348b.tar.gz
Document buffer size limitations of nl_recv()
-rw-r--r--lib/nl.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/nl.c b/lib/nl.c
index 9858307..0ed248e 100644
--- a/lib/nl.c
+++ b/lib/nl.c
@@ -416,9 +416,16 @@ errout:
* are handled by repeating the read. The input buffer size is determined
* by peeking before the actual read is done.
*
+ * The buffer size used when reading from the netlink socket and thus limiting
+ * the maximum size of a netlink message that can be read defaults to the size
+ * of a memory page (getpagesize()). The buffer size can be modified on a per
+ * socket level using the function nl_socket_set_msg_buf_size().
+ *
* A non-blocking sockets causes the function to return immediately with
* a return value of 0 if no data is available.
*
+ * @see nl_socket_set_msg_buf_size()
+ *
* @return Number of octets read, 0 on EOF or a negative error code.
*/
int nl_recv(struct nl_sock *sk, struct sockaddr_nl *nla,