--- libaitrpc/inc/aitrpc.h 2012/03/13 17:21:52 1.5.2.5 +++ libaitrpc/inc/aitrpc.h 2012/03/14 13:29:11 1.5.2.6 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: aitrpc.h,v 1.5.2.5 2012/03/13 17:21:52 misho Exp $ +* $Id: aitrpc.h,v 1.5.2.6 2012/03/14 13:29:11 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -496,10 +496,21 @@ int rpc_cli_delBLOB(rpc_cli_t * __restrict cli, ait_va * @data = BLOB data, must be free after use! * return: -1 error, 0 ok, >0 remote error */ -inline int rpc_cli_getBLOB(rpc_cli_t * __restrict cli, ait_val_t * __restrict var, void ** __restrict data); +inline int rpc_cli_getBLOB(rpc_cli_t * __restrict cli, ait_val_t * __restrict var, + void ** __restrict data); +/* + * rpc_calcHashes() - Calculate hashes for RPC call + * + * @func = function + * @csModule = Module name, if NULL self binary + * @csFunc = Function name + * return: -1 error or 0 ok + */ +int rpc_calcHashes(rpc_func_t * __restrict func, const char *csModule, const char *csFunc); + /* RPC Client side functions */ /* @@ -508,13 +519,15 @@ inline int rpc_cli_getBLOB(rpc_cli_t * __restrict cli, * @ProgID = ProgramID for RPC session request * @ProcID = ProcessID for RPC session request * @netBuf = Network buffer length, if =0 == BUFSIZ (also meaning max RPC packet) + * @Timeout = RPC timeout in seconds, if =0 set default RPC timeout * @family = Family socket type, AF_INET or AF_INET6 * @csHost = Host name or IP address for bind server * @Port = Port for bind server, if Port == 0 default port is selected * return: NULL == error or !=NULL connection to RPC server established */ -rpc_cli_t *rpc_cli_openClient(u_int ProgID, u_int ProcID, int netBuf, - u_short family, const char *csHost, u_short Port); +rpc_cli_t *rpc_cli_openClient(unsigned int ProgID, unsigned int ProcID, int netBuf, + unsigned char Timeout, unsigned short family, + const char *csHost, unsigned short Port); /* * rpc_cli_closeClient() - Close connection to RPC server and free resources *