Diffstat (limited to 'libipq/ipq_read.3')
1 files changed, 95 insertions, 0 deletions
diff --git a/libipq/ipq_read.3 b/libipq/ipq_read.3
new file mode 100644
@@ -0,0 +1,95 @@
+.TH IPQ_READ 3 "18 November 2000" "Linux iptables 1.1.3+" "Linux Programmer's Manual"
+.\" $Id: $
+.\" Copyright (c) 2000 Netfilter Core Team
+.\" This program is free software; you can redistribute it and/or modify
+.\" it under the terms of the GNU General Public License as published by
+.\" the Free Software Foundation; either version 2 of the License, or
+.\" (at your option) any later version.
+.\" This program is distributed in the hope that it will be useful,
+.\" but WITHOUT ANY WARRANTY; without even the implied warranty of
+.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+.\" GNU General Public License for more details.
+.\" You should have received a copy of the GNU General Public License
+.\" along with this program; if not, write to the Free Software
+.\" Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ipq_read - wait for queue messages from ip_queue and read into supplied buffer
+.B #include <linux/netfilter.h>
+.B #include <libipq.h>
+.BI "ssize_t ipq_read(const struct ipq_handle *" h ", unsigned char *" buf ", size_t " len ", int " timeout ");"
+function waits for a queue message to arrive from the kernel and copies it to
+the memory pointed to by
+to a maximum length of
+. I len .
+parameter is a context handle which must previously have been returned
+successfully from a call to
+.B ipq_create_handle .
+The caller is responsible for ensuring that the memory pointed to by
+is large enough to contain
+parameter is not currently implemented.
+Data returned via
+should not be accessed directly. Use the
+.BR ipq_message_type ,
+.BR ipq_get_packet ", and"
+functions to access the queue message in the buffer.
+.SH RETURN VALUE
+On failure, -1 is returned.
+On success, a non-zero positive value is returned.
+On error, a descriptive error message will be available
+function may return successfully, the queue message copied to the buffer
+may itself be an error message from a higher level kernel component. Use
+to determine if it is an error message, and
+to access the value of the message.
+as part of a non-blocking interface.
+James Morris <email@example.com>
+Copyright (c) 2000 Netfilter Core Team.
+Distributed under the GNU General Public License.
+.SH SEE ALSO
+.BR iptables (8),
+.BR libipq (3).