HIPC  0.5
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
Data Structures | Enumerations | Functions
client.h File Reference
#include <stddef.h>
#include <hipc.h>
#include <hipc/msg.h>
Include dependency graph for client.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  HIPC_cl_indp_mbr
 Machine-independent information of a member of a structure used in a client. More...
 
struct  HIPC_cl_indp_stru
 Machine-independent information of a structure used in a client. More...
 
struct  HIPC_cl_indp
 Machine-independent information of a client. More...
 
struct  HIPC_cl_dp_stru
 Machine-dependent information of a structure used in a client. More...
 
struct  HIPC_cl_dp
 Machine-dependent information of a client. More...
 
struct  HIPC_ptr_link_list
 
struct  HIPC_client
 

Enumerations

enum  HIPC_member_type { HIPC_MBR_SIMPLE, HIPC_MBR_STRUCT, HIPC_MBR_ARRAY }
 

Functions

void hipcClientSetStdErrno (struct HIPC_client *const cl_p)
 Sets errno value to a HIPC client. More...
 
int hipcClientGetStdErrno (const struct HIPC_client *const cl_p)
 Gets an errno value saved by hipcClientSetStdErrno(). More...
 
enum HIPC_errno hipcClientGetHipcErrno (const struct HIPC_client *const cl_p)
 Gets a HIPC error number that has been set. More...
 
const char * hipcClientGetErrStr (const struct HIPC_client *const cl_p)
 Gets a string describing a HIPC error number that has been set to a HIPC client. More...
 
const char * hipcClientGetErrDtlStr (const struct HIPC_client *const cl_p)
 Gets a string describing details of an error that has been set to a HIPC client. More...
 
enum HIPC_errno hipcClientSetError (struct HIPC_client *const cl_p, enum HIPC_errno hipc_errno, const char *const str)
 Sets an error to a client with error detail. More...
 
void hipcClientSetCimg (struct HIPC_client *const cl_p, const unsigned char struno, void *cimg_p)
 Sets a client-side image that is a structure instance of a structure. More...
 
void hipcClientSetHandler (struct HIPC_client *const cl_p, const unsigned char struno, enum HIPC_errno(*hndlr_p)(struct HIPC_client *, const hipc_msg, void *, void *), void *const arg)
 Sets an handler hndlr_p to a structure number struno. More...
 
enum HIPC_errno hipcClientCallHandler (struct HIPC_client *const cl_p, const unsigned char struno, const hipc_msg msgR)
 Calls a handler that corresponds to struno. More...
 
unsigned char hipcClientGetNsysmsg (struct HIPC_client const *const cl_p)
 Gets the number of system messages. More...
 
enum HIPC_errno hipcClientInit (struct HIPC_client *const cl_p, struct HIPC_client const *const clbase_p)
 Initializes a HIPC client with allocating memory space if necessary. More...
 
void hipcClientTerminate (struct HIPC_client *const cl_p)
 Terminates a HIPC client with releasing the memory space that the client has. More...
 
enum HIPC_errno hipcClientCheckMbrSize (struct HIPC_client *const cl_p)
 Checks whether sizes of members in structures in a server are the same as sizes in a client. More...
 
enum HIPC_errno hipcClientCheckStrutpl (struct HIPC_client *const cl_p, const unsigned char struno, const size_t offset, const size_t size)
 Checks a combination of a structure number, an offset, and a size for a HIPC message. More...
 
enum HIPC_errno hipcClientGetStrutpl (struct HIPC_client *const cl_p, char const *const str, unsigned char *struno_p, size_t *offset_p, size_t *size_p)
 Gets structure number, offset, and size from ID string. More...
 
enum HIPC_errno hipcClientEachMbr (struct HIPC_client *const cl_p, struct HIPC_cl_indp_mbr const *const mbr_p, unsigned char *const begin, unsigned char *const end, unsigned char *const scur_p, unsigned char *const ccur_p, const size_t ssize, const size_t csize, void(*fnc_p)(void *const ccur_p, void *const scur_p, const size_t n))
 Calls the function specified by fnc_p with each member between begin and end. More...
 
enum HIPC_errno hipcClientUnpack (struct HIPC_client *const cl_p, const unsigned char struno, const size_t offset, const size_t size, void *simg, void *cimg)
 Unpacks a range of contents of simg into cimg. More...
 
enum HIPC_errno hipcClientPack (struct HIPC_client *const cl_p, const unsigned char struno, const size_t offset, const size_t size, void *simg, void *cimg)
 Packs a range of contents of cimg into simg. More...
 
enum HIPC_errno hipcClientFeedUnstrumsgAsError (struct HIPC_client *const cl_p, const hipc_msg msgR)
 Feeds a message and sets an error specified by the message. More...
 
enum HIPC_errno hipcClientFeedSysmsg (struct HIPC_client *const cl_p, const hipc_msg msgR)
 Feeds a system message and incorporates it to the internal data of the client. More...
 
enum HIPC_errno hipcClientFeedStrumsg (struct HIPC_client *const cl_p, const hipc_msg msgR)
 Feeds a message and incorporates it to the internal data of a client. More...
 
void hipcGenmsgHello (hipc_msg msg, const struct HIPC_client *const cl_p)
 Generates HELLO message. More...
 
enum HIPC_errno hipcGenmsgGet (hipc_msg msg, struct HIPC_client *const cl_p, const unsigned char struno, const size_t offset, const size_t size)
 Generates GET message. More...
 
enum HIPC_errno hipcGenmsgPut (hipc_msg msg, struct HIPC_client *const cl_p, const unsigned char struno, const size_t offset, const size_t size)
 Generates PUT message. More...
 
void hipcGenmsgBye (hipc_msg msg)
 Initializes a HIPC message as a BYE message. More...
 

Enumeration Type Documentation

Enumerator
HIPC_MBR_SIMPLE 
HIPC_MBR_STRUCT 
HIPC_MBR_ARRAY 

Definition at line 9 of file client.h.

Function Documentation

void hipcClientSetStdErrno ( struct HIPC_client *const  cl_p)

Sets errno value to a HIPC client.

The value comes from errno in the C standard library, so this function takes no arguments.

Parameters
cl_ppointer to the HIPC client
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 119 of file client.c.

References HIPC_client::std_errno.

Referenced by hipcRecvMsg(), and hipcSendMsg().

Here is the caller graph for this function:

int hipcClientGetStdErrno ( const struct HIPC_client *const  cl_p)

Gets an errno value saved by hipcClientSetStdErrno().

Parameters
cl_ppointer to a HIPC client
Returns
errno value

Definition at line 131 of file client.c.

References HIPC_client::std_errno.

Referenced by hipcERRCHECK().

Here is the caller graph for this function:

enum HIPC_errno hipcClientGetHipcErrno ( const struct HIPC_client *const  cl_p)

Gets a HIPC error number that has been set.

Parameters
cl_ppointer to a HIPC client
Returns
HIPC error number

Definition at line 143 of file client.c.

References HIPC_client::hipc_errno.

Referenced by hipcERRCHECK(), and hipcWaitReturn().

Here is the caller graph for this function:

const char* hipcClientGetErrStr ( const struct HIPC_client *const  cl_p)

Gets a string describing a HIPC error number that has been set to a HIPC client.

Parameters
cl_ppointer to the HIPC client
Returns
string describing the error

Definition at line 155 of file client.c.

References HIPC_client::hipc_errno, and HIPC_N_ERR.

Referenced by hipcERRCHECK().

Here is the caller graph for this function:

const char* hipcClientGetErrDtlStr ( const struct HIPC_client *const  cl_p)

Gets a string describing details of an error that has been set to a HIPC client.

Parameters
cl_ppointer to the HIPC client
Returns
string describing details of the error

Definition at line 171 of file client.c.

References HIPC_client::err_detail_str.

Referenced by hipcERRCHECK().

Here is the caller graph for this function:

enum HIPC_errno hipcClientSetError ( struct HIPC_client *const  cl_p,
enum HIPC_errno  hipc_errno,
char const *const  str 
)

Sets an error to a client with error detail.

Parameters
cl_ppointer to the HIPC client
hipc_errnoHIPC error number to be set
strstring of the error detail
Returns
the same value as hipc_errno.

Definition at line 240 of file client.c.

References HIPC_client::hipc_errno.

Referenced by hipcClientCheckStrutpl(), hipcClientEachMbr(), hipcClientFeedSysmsg(), hipcClientFeedUnstrumsgAsError(), hipcClientInit(), hipcGet(), hipcPut(), hipcRecvMsg(), hipcSendMsg(), hipcSetHandler(), and hipcWaitReturn().

Here is the caller graph for this function:

void hipcClientSetCimg ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
void *  cimg_p 
)

Sets a client-side image that is a structure instance of a structure.

cimg_p points the client-side image. struno must correspond to the type of the client-side image.

Parameters
cl_ppointer to a HIPC client
strunostructure number
cimg_paddress that points the structure instance

Definition at line 260 of file client.c.

References HIPC_client::cimg_pp.

Referenced by hipcSetHandler().

Here is the caller graph for this function:

void hipcClientSetHandler ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
enum HIPC_errno(*)(struct HIPC_client *, const hipc_msg, void *, void *)  hndlr_p,
void *const  arg 
)

Sets an handler hndlr_p to a structure number struno.

arg will be passed to the handler when the handler is called.

Parameters
cl_ppointer to a HIPC client
strunostructure number
hndlr_pfunction pointer, which is the handler.
argargument for the handler

Definition at line 279 of file client.c.

References HIPC_client::hdarg_pp, and HIPC_client::hndlr_pp.

Referenced by hipcSetHandler().

Here is the caller graph for this function:

enum HIPC_errno hipcClientCallHandler ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
const hipc_msg  msgR 
)

Calls a handler that corresponds to struno.

msgR is passed to the handler as an argument.

Parameters
cl_ppointer to a HIPC client
strunostructure number
msgRHIPC message to be passed to the handler
Returns
what the handler returns

Definition at line 303 of file client.c.

References HIPC_client::cimg_pp, HIPC_client::hdarg_pp, HIPC_SUCCESS, and HIPC_client::hndlr_pp.

Referenced by hipcWaitReturn().

Here is the caller graph for this function:

unsigned char hipcClientGetNsysmsg ( struct HIPC_client const *const  cl_p)

Gets the number of system messages.

Parameters
cl_pPointer to a HIPC client
Returns
Number of system messages

Definition at line 326 of file client.c.

References HIPC_client::indp_p, and HIPC_cl_indp::n_sysmsg.

Referenced by hipcOpen().

Here is the caller graph for this function:

enum HIPC_errno hipcClientInit ( struct HIPC_client *const  cl_p,
struct HIPC_client const *const  clbase_p 
)

Initializes a HIPC client with allocating memory space if necessary.

Parameters
cl_ppointer to a HIPC client to be initialized. This must not be NULL.
clbase_ppointer to a HIPC client with which cl_p is initialized.
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 339 of file client.c.

References HIPC_client::cimg_pp, HIPC_client::cmdp_p, HIPC_cl_dp::endian, HIPC_client::endian_convert, HIPC_client::err_detail_str, HIPC_client::hdarg_pp, HIPC_ERR_INV_BASE_CLIENT, HIPC_ERR_INV_ENDIAN, HIPC_client::hipc_errno, HIPC_SUCCESS, hipcClientSetError(), hipcEndian(), HIPC_client::hndlr_pp, HIPC_client::indp_p, HIPC_cl_indp::n_struct, HIPC_client::pllist_p, HIPC_client::simg_pp, HIPC_client::smdp_p, HIPC_client::std_errno, HIPC_cl_dp::struct_p, and HIPC_cl_dp::struct_size_p.

Referenced by hipcOpen().

Here is the call graph for this function:

Here is the caller graph for this function:

void hipcClientTerminate ( struct HIPC_client *const  cl_p)

Terminates a HIPC client with releasing the memory space that the client has.

Parameters
cl_ppointer to a HIPC client

Definition at line 438 of file client.c.

References HIPC_ptr_link_list::next, HIPC_client::pllist_p, and HIPC_ptr_link_list::ptr.

Referenced by hipcClose().

Here is the caller graph for this function:

enum HIPC_errno hipcClientCheckMbrSize ( struct HIPC_client *const  cl_p)

Checks whether sizes of members in structures in a server are the same as sizes in a client.

Only sizes of structures may differ.

Parameters
cl_ppointer to a HIPC client
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 458 of file client.c.

References HIPC_client::cmdp_p, HIPC_cl_indp_mbr::elm_type, HIPC_ERR_MBR_SIZE_MISMATCH, HIPC_client::hipc_errno, HIPC_MBR_ARRAY, HIPC_MBR_SIMPLE, HIPC_SUCCESS, HIPC_client::indp_p, HIPC_cl_indp_stru::mbr_p, HIPC_cl_indp_stru::n_member, HIPC_cl_indp::n_struct, HIPC_cl_indp_mbr::name, HIPC_cl_indp_stru::name, HIPC_cl_dp_stru::size_p, HIPC_client::smdp_p, HIPC_cl_indp::struct_p, HIPC_cl_dp::struct_p, and HIPC_cl_indp_mbr::type.

Referenced by hipcOpen().

Here is the caller graph for this function:

enum HIPC_errno hipcClientCheckStrutpl ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
const size_t  offset,
const size_t  rngsize 
)

Checks a combination of a structure number, an offset, and a size for a HIPC message.

Parameters
cl_ppointer to a HIPC client
strunostructure number for a message
offsetoffset for a message
rngsizerange size for a message
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 509 of file client.c.

References HIPC_ERR_PROTOCOL_VIOLATION, HIPC_SUCCESS, hipcClientSetError(), HIPC_client::indp_p, HIPC_cl_indp::n_struct, HIPC_client::smdp_p, and HIPC_cl_dp::struct_size_p.

Referenced by hipcClientFeedStrumsg(), hipcClientGetStrutpl(), hipcClientPack(), hipcClientUnpack(), hipcGenmsgGet(), and hipcGenmsgPut().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientGetStrutpl ( struct HIPC_client *const  cl_p,
char const *const  str,
unsigned char *  struno_p,
size_t *  offset_p,
size_t *  size_p 
)

Gets structure number, offset, and size from ID string.

Parameters
cl_ppointer to a HIPC client
strstring that identifies an item
struno_ppointer to receive the structure number
offset_ppointer to receive the offset value
size_ppointer to receive the size
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 698 of file client.c.

References HIPC_ERR_INV_ID_STR, HIPC_client::hipc_errno, HIPC_MBR_STRUCT, HIPC_SUCCESS, hipcClientCheckStrutpl(), HIPC_client::indp_p, HIPC_cl_indp::n_struct, HIPC_cl_indp_stru::name, HIPC_client::smdp_p, HIPC_cl_indp::struct_p, HIPC_cl_dp::struct_size_p, HIPC_cl_indp_mbr::struno, and HIPC_cl_indp_mbr::type.

Referenced by hipcGet(), hipcPut(), and hipcSetHandler().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientEachMbr ( struct HIPC_client *const  cl_p,
struct HIPC_cl_indp_mbr const *const  mbr_p,
unsigned char *const  begin,
unsigned char *const  end,
unsigned char *const  scur_p,
unsigned char *const  ccur_p,
const size_t  ssize,
const size_t  csize,
void(*)(void *const ccur_p, void *const scur_p, const size_t n)  fnc_p 
)

Calls the function specified by fnc_p with each member between begin and end.

When mbr_p points structure type, zeros can be passed as ssize and csize.

Parameters
cl_ppointer to a HIPC client.
mbr_ppointer to an object that has data of the member.
beginbeginning address in the image for the server.
endending address in the image for the server.
scur_pserver's cuurent pointer.
ccur_pclient's cuurent pointer.
ssizesize of the item (member) in the server
csizesize of the item (member) in the client
fnc_ppointer to the function to be called.
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 756 of file client.c.

References HIPC_cl_indp_mbr::ary_dim, HIPC_cl_indp_mbr::ary_max_idxs, HIPC_client::cmdp_p, HIPC_cl_indp_mbr::elm_struno, HIPC_cl_indp_mbr::elm_type, HIPC_ERR_INTERNAL_ERROR, HIPC_MBR_ARRAY, HIPC_MBR_SIMPLE, HIPC_MBR_STRUCT, HIPC_SUCCESS, hipcClientEachMbr(), hipcClientSetError(), HIPC_client::indp_p, HIPC_cl_indp_stru::mbr_p, HIPC_cl_indp_stru::n_member, HIPC_cl_dp_stru::offset_p, HIPC_cl_dp_stru::size_p, HIPC_client::smdp_p, HIPC_cl_indp::struct_p, HIPC_cl_dp::struct_p, HIPC_cl_indp_mbr::struno, and HIPC_cl_indp_mbr::type.

Referenced by hipcClientEachMbr(), hipcClientPack(), and hipcClientUnpack().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientUnpack ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
const size_t  offset,
const size_t  size,
void *  simg,
void *  cimg 
)

Unpacks a range of contents of simg into cimg.

struno, offset, and size determine the range. If simg is NULL, this function uses memory that has been internally allocated. If cimg is NULL, this function uses memory that was set by hipcClientSetCimg(). If cimg is NULL and no memory has been set yet, this function does nothing.

Parameters
cl_ppointer to a HIPC client.
strunostructure number for the structure to be unpacked
offsetoffset of the range in the server representation
sizesize of the range in the server representation
simgServer-side image of the structure
cimgClient-side image of the structure
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 908 of file client.c.

References HIPC_client::cimg_pp, HIPC_client::endian_convert, HIPC_MBR_STRUCT, HIPC_SUCCESS, hipcClientCheckStrutpl(), hipcClientEachMbr(), HIPC_client::simg_pp, HIPC_cl_indp_mbr::struno, and HIPC_cl_indp_mbr::type.

Referenced by hipcGet(), and hipcWaitReturn().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientPack ( struct HIPC_client *const  cl_p,
const unsigned char  struno,
const size_t  offset,
const size_t  size,
void *  simg,
void *  cimg 
)

Packs a range of contents of cimg into simg.

struno, offset, and size determine the range. If simg is NULL, this function uses memory that has been internally allocated. If cimg is NULL, this function uses memory that was set by hipcClientSetCimg(). If cimg is NULL and no memory has been set yet, this function does nothing.

Parameters
cl_ppointer to a HIPC client.
strunostructure number for the structure to be packed
offsetoffset of the range in the server representation
sizesize of the range in the server representation
simgServer-side image of the structure
cimgClient-side image of the structure
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 962 of file client.c.

References HIPC_client::cimg_pp, HIPC_client::endian_convert, HIPC_MBR_STRUCT, HIPC_SUCCESS, hipcClientCheckStrutpl(), hipcClientEachMbr(), HIPC_client::simg_pp, HIPC_cl_indp_mbr::struno, and HIPC_cl_indp_mbr::type.

Referenced by hipcPut().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientFeedUnstrumsgAsError ( struct HIPC_client *const  cl_p,
const hipc_msg  msgR 
)

Feeds a message and sets an error specified by the message.

The message must have an unstructured body.

Parameters
cl_ppointer to a HIPC client.
msgRmessage to be fed
Returns
HIPC_ERR_PROTOCOL_VIOLATION if the message is inappropriate, or an error specified by the message.

Definition at line 1011 of file client.c.

References HIPC_client::err_detail_str, HIPC_ERR_PROTOCOL_VIOLATION, HIPC_client::hipc_errno, HIPC_IMG_ALLOCSIZE, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_SIZE, HIPC_UNSTRU, and hipcClientSetError().

Referenced by hipcOpen(), and hipcWaitReturn().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientFeedSysmsg ( struct HIPC_client *const  cl_p,
const hipc_msg  msgR 
)

Feeds a system message and incorporates it to the internal data of the client.

Parameters
cl_ppointer to a HIPC client.
msgRsystem message to be fed
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 1087 of file client.c.

References HIPC_client::cmdp_p, HIPC_cl_dp::endian, HIPC_client::endian_convert, HIPC_ERR_INV_ENDIAN, HIPC_ERR_PROTOCOL_VIOLATION, HIPC_client::hipc_errno, HIPC_MESSAGE_TYPE_SYS, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_BYTE_TYPE, HIPC_MSGHDR_SIZE, HIPC_SUCCESS, HIPC_SYSMSG_TYPE_OFFSET, HIPC_SYSMSG_TYPE_OVERVIEW, HIPC_SYSMSG_TYPE_SIZE, hipcClientSetError(), HIPC_client::indp_p, HIPC_cl_indp::n_struct, HIPC_cl_dp_stru::offset_p, HIPC_client::simg_pp, HIPC_cl_dp_stru::size_p, HIPC_client::smdp_p, HIPC_cl_dp::struct_p, HIPC_cl_dp::struct_size_p, and HIPC_cl_indp_mbr::struno.

Referenced by hipcOpen().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcClientFeedStrumsg ( struct HIPC_client *const  cl_p,
const hipc_msg  msgR 
)

Feeds a message and incorporates it to the internal data of a client.

The message must have a structured body.

Parameters
cl_ppointer to a HIPC client.
msgRmessage to be fed
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 1174 of file client.c.

References HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_SIZE, HIPC_SUCCESS, hipcClientCheckStrutpl(), and HIPC_client::simg_pp.

Referenced by hipcWaitReturn().

Here is the call graph for this function:

Here is the caller graph for this function:

void hipcGenmsgHello ( hipc_msg  msg,
const struct HIPC_client *const  cl_p 
)

Generates HELLO message.

Parameters
cl_ppointer to a HIPC client
msgHIPC message to be set as HELLO
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 1201 of file client.c.

References HIPC_cl_indp::cfgid, HIPC_cl_indp::cfgid_size, HIPC_MESSAGE_TYPE_HELLO, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_BYTE_TYPE, HIPC_MSGHDR_SIZE, HIPC_UNSTRU, and HIPC_client::indp_p.

Referenced by hipcOpen().

Here is the caller graph for this function:

enum HIPC_errno hipcGenmsgGet ( hipc_msg  msg,
struct HIPC_client *const  cl_p,
const unsigned char  struno,
const size_t  offset,
const size_t  size 
)

Generates GET message.

Parameters
cl_ppointer to a HIPC client
msgHIPC message to be set as GET
strunostructure number of the message
offsetoffset of the message
sizesize of the message
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 1223 of file client.c.

References HIPC_MESSAGE_TYPE_GET, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_BYTE_TYPE, HIPC_SUCCESS, hipcClientCheckStrutpl(), and HIPC_cl_indp_mbr::struno.

Referenced by hipcGet().

Here is the call graph for this function:

Here is the caller graph for this function:

enum HIPC_errno hipcGenmsgPut ( hipc_msg  msg,
struct HIPC_client *const  cl_p,
const unsigned char  struno,
const size_t  offset,
const size_t  size 
)

Generates PUT message.

Parameters
cl_ppointer to a HIPC client
msgHIPC message to be set as PUT
strunostructure number of the message
offsetoffset of the message
sizesize of the message
Returns
HIPC_SUCCESS on success, or an error on failure.

Definition at line 1253 of file client.c.

References HIPC_MESSAGE_TYPE_PUT, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_BYTE_TYPE, HIPC_MSGHDR_SIZE, HIPC_SUCCESS, hipcClientCheckStrutpl(), HIPC_client::simg_pp, and HIPC_cl_indp_mbr::struno.

Referenced by hipcPut().

Here is the call graph for this function:

Here is the caller graph for this function:

void hipcGenmsgBye ( hipc_msg  msg)

Initializes a HIPC message as a BYE message.

Parameters
msgHIPC message to be initialized as BYE

Definition at line 1279 of file client.c.

References HIPC_MESSAGE_TYPE_BYE, HIPC_MSGHDR_BYTE_BDYSZ, HIPC_MSGHDR_BYTE_OFFSET, HIPC_MSGHDR_BYTE_STRUNO, HIPC_MSGHDR_BYTE_TYPE, and HIPC_UNSTRU.

Referenced by hipcClose().

Here is the caller graph for this function: