--- version: v1.2.5 layout: manpage title: nn_freemsg(3compat) ---
{% if page.version and page.version != site.latest %} {% if page.version == "tip" %} {% include manpage-tip.html %} {% else %} {% include manpage-old.html %} {% endif %} {% endif %}

SYNOPSIS

#include <nanomsg/nn.h>

int nn_freemsg(void *msg);

DESCRIPTION

The nn_freemsg() deallocates a message previously allocated with nn_allocmsg() or similar functions.

This function is provided for API compatibility with legacy libnanomsg. Consider using the relevant modern API instead.

RETURN VALUES

This function always returns 0.

ERRORS

None.