Greenbone Vulnerability Manager  8.0.1~git
Functions
comm.h File Reference

Protos for communication between gvmd and openvassd. More...

#include <glib.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/types.h>

Go to the source code of this file.

Functions

int send_to_server (const char *)
 Send a message to the server. More...
 
int sendf_to_server (const char *,...)
 Format and send a message to the server. More...
 
int sendn_to_server (const void *, size_t)
 Send a number of bytes to the server. More...
 
unsigned int to_server_buffer_space ()
 Get the number of characters free in the server output buffer. More...
 

Detailed Description

Protos for communication between gvmd and openvassd.

This file contains the protos for comm.c

Function Documentation

◆ send_to_server()

int send_to_server ( const char *  msg)

Send a message to the server.

Parameters
[in]msgThe message, a string.
Returns
0 for success, any other value for failure.

◆ sendf_to_server()

int sendf_to_server ( const char *  format,
  ... 
)

Format and send a message to the server.

Parameters
[in]formatprintf-style format string for message.
Returns
0 for success, any other value for failure.

◆ sendn_to_server()

int sendn_to_server ( const void *  msg,
size_t  n 
)

Send a number of bytes to the server.

Parameters
[in]msgThe message, a sequence of bytes.
[in]nThe number of bytes from msg to send.
Returns
0 for success, any other value for failure.

◆ to_server_buffer_space()

unsigned int to_server_buffer_space ( )

Get the number of characters free in the server output buffer.

Returns
Number of characters free in server output buffer. 0 when full.