---
name: "ipq_errstr"
section: "3"
platform: "linux"
package: "iptables"
version: "1:1.8.13-1"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/ipq_errstr"
---

# ipq\_errstr(3)

libipq error handling routines

## NAME

ipq\_errstr, ipq\_perror — libipq error handling routines

## SYNOPSIS

**#include \<linux/netfilter.h\>**\
 **#include \<libipq.h\>**

**char \*ipq\_errstr(***void***);**\
 **void ipq\_perror(const char \****s***);**

## DESCRIPTION

The **ipq\_errstr** function returns a descriptive error message based on the current value of the internal **ipq\_errno** variable.  All libipq API functions set this internal variable upon failure.

The **ipq\_perror** function prints an error message to stderr corresponding to the current value of the internal **ipq\_error** variable, and the global **errno** variable (if set).  The error message is prefixed with the string *s* as supplied by the application. If *s* is NULL, the error message is prefixed with the string "ERROR".

## RETURN VALUE

**ipq\_errstr** returns an error message as outlined above.

## BUGS

None known.

## AUTHOR

James Morris \<jmorris@intercode.com.au\>

## COPYRIGHT

Copyright (c) 2000-2001 Netfilter Core Team.

Distributed under the GNU General Public License.

## SEE ALSO

[**iptables**(8)](/iptables/8.md), [**libipq**(3)](/libipq/3.md).
