---
name: "zmq_errno"
section: "3"
platform: "linux"
package: "zeromq"
version: "4.3.5-3"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/zmq_errno"
---

# zmq\_errno(3)

retrieve value of errno for the calling thread

## NAME

zmq\_errno - retrieve value of errno for the calling thread

## SYNOPSIS

**int zmq\_errno (void);**

## DESCRIPTION

The *zmq\_errno()* function shall retrieve the value of the *errno* variable for the calling thread.

The *zmq\_errno()* function is provided to assist users on non-POSIX systems who are experiencing issues with retrieving the correct value of *errno* directly. Specifically, users on Win32 systems whose application is using a different C run-time library from the C run-time library in use by 0MQ will need to use *zmq\_errno()* for correct operation.

**Important**\

Users not experiencing issues with retrieving the correct value of *errno* should not use this function and should instead access the *errno* variable directly.

## RETURN VALUE

The *zmq\_errno()* function shall return the value of the *errno* variable for the calling thread.

## ERRORS

No errors are defined.

## SEE ALSO

[**zmq**(7)](/zmq/7.md)

## AUTHORS

This page was written by the 0MQ community. To make a change please read the 0MQ Contribution Policy at **http://www.zeromq.org/docs:contributing**.
