Function amqp_socket_recv

Synopsis

#include <librabbitmq/amqp_socket.h>

ssize_t amqp_socket_recv(amqp_socket_t *self, void *buf, size_t len, int flags)

Description

Receive a message from a socket.

This function wraps recv(2) functionality.

Parameters:

[ in,out ] self - A socket object.

[ out ] buf - A buffer to write to.

[ in ] len - The number of bytes at buf.

[ in ] flags - Receive flags, implementation specific.

Return
The number of bytes received, or < 0 on error (amqp_status_enum)

Source

Lines 128-133 in librabbitmq/amqp_socket.c. Line 121 in librabbitmq/amqp_socket.h.

ssize_t amqp_socket_recv(amqp_socket_t *self, void *buf, size_t len,
                         int flags) {
  assert(self);
  assert(self->klass->recv);
  return self->klass->recv(self, buf, len, flags);
}





Add Discussion as Guest

Log in to DocsForge