<commit_before>xallocmsg(3)
==============

NAME
----
xallocmsg - allocate a message


SYNOPSIS
--------
*#include <xio/sock.h>*

*void *xallocmsg (size_t 'size');*


DESCRIPTION
-----------
Allocate a message of the specified 'size' to be sent in zero-copy fashion.
The content of the message is undefined after allocation and it should be filled
in by the user.

RETURN VALUE
------------
On success, zero is returned.  On error, -1 is returned, and errno is set
appropriately.

ERRORS
------
*EINVAL*::
Supplied allocation 'size' is invalid.
*ENOMEM*::
Not enough memory to allocate the message.


EXAMPLE
-------

----
void *buf = xallocmsg (12);
memcpy (buf, "Hello world!", 12);
xsend (s, &buf);
----


SEE ALSO
--------
linkxio:xfreemsg[3]
linkxio:xsend[3]
linkxio:xio[7]

AUTHORS
-------
<NAME> <<EMAIL>>
<NAME> <<EMAIL>>

<commit_msg>[feature] fix xallocmsg doc<commit_after>xallocmsg(3)
==============

NAME
----
xallocmsg - allocate a message


SYNOPSIS
--------
*#include <xio/sock.h>*

*void *xallocmsg (size_t 'size');*


DESCRIPTION
-----------
Allocate a message of the specified 'size' to be sent in zero-copy fashion.
The content of the message is undefined after allocation and it should be filled
in by the user.

RETURN VALUE
------------
On success, zero is returned.  On error, -1 is returned, and errno is set
appropriately.

ERRORS
------
*EINVAL*::
Supplied allocation 'size' is invalid.
*ENOMEM*::
Not enough memory to allocate the message.


EXAMPLE
-------

----
void *buf = xallocmsg (12);
memcpy (buf, "Hello world!", 12);
xsend (s, buf);
----


SEE ALSO
--------
linkxio:xfreemsg[3]
linkxio:xsend[3]
linkxio:xio[7]

AUTHORS
-------
<NAME> <<EMAIL>>
<NAME> <<EMAIL>>


{'fraction_non_alphanumeric': 0.1983519717480871, 'fraction_numerical': 0.01059446733372572, 'mean_word_length': 2.9906103286384975, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4633968', 'n_tokens_mistral': 599, 'n_tokens_neox': 578, 'n_words': 203}