adjmsg(9r) adjmsg(9r)
NAME
adjmsg - STREAMS: Removes the specified number of bytes from a message
SYNOPSIS
#include <sys/stream.h>
int adjmsg(
MBLKP message_ptr,
int len_to_trim );
ARGUMENTS
Specifies a pointer to the message that you want adjmsg to trim. Specifies the number of bytes that you want adjmsg to remove (trim) from
the message.
DESCRIPTION
The adjmsg interface removes a specified number of bytes from a message. The absolute value of the len_to_trim argument specifies how many
bytes that adjmsg removes. If the number of bytes passed to len_to_trim is greater than 0 (zero), adjmsg removes bytes from the head of
the message. If the number of bytes passed to len_to_trim is less than 0 (zero), adjmsg removes bytes from the tail of the message.
The adjmsg interface fails if the value you pass to the len_to_trim argument is greater than the number of bytes stored in the message
pointer argument, message_ptr.
RETURN VALUES
If the adjmsg interface successfully trims the message, it returns the value 1. Otherwise, it returns the value 0 (zero).
adjmsg(9r)