mirror of
https://github.com/zeromq/libzmq.git
synced 2025-01-31 14:39:55 +01:00
Changed return type of zmq_msg_size to ssize_t to allow error return
This commit is contained in:
parent
dc09da4569
commit
02b81d42ce
@ -167,14 +167,14 @@ ZMQ_EXPORT int zmq_msg_close (zmq_msg_t *msg);
|
||||
ZMQ_EXPORT int zmq_msg_move (zmq_msg_t *dest, zmq_msg_t *src);
|
||||
ZMQ_EXPORT int zmq_msg_copy (zmq_msg_t *dest, zmq_msg_t *src);
|
||||
ZMQ_EXPORT void *zmq_msg_data (zmq_msg_t *msg);
|
||||
ZMQ_EXPORT size_t zmq_msg_size (zmq_msg_t *msg);
|
||||
|
||||
ZMQ_EXPORT ssize_t zmq_msg_size (zmq_msg_t *msg);
|
||||
ZMQ_EXPORT int zmq_msg_more (zmq_msg_t *msg);
|
||||
ZMQ_EXPORT int zmq_msg_get (zmq_msg_t *msg, int option, void *optval,
|
||||
size_t *optvallen);
|
||||
ZMQ_EXPORT int zmq_msg_set (zmq_msg_t *msg, int option, const void *optval,
|
||||
size_t *optvallen);
|
||||
|
||||
|
||||
/******************************************************************************/
|
||||
/* 0MQ infrastructure (a.k.a. context) initialisation & termination. */
|
||||
/******************************************************************************/
|
||||
|
@ -576,7 +576,7 @@ void *zmq_msg_data (zmq_msg_t *msg_)
|
||||
return ((zmq::msg_t*) msg_)->data ();
|
||||
}
|
||||
|
||||
size_t zmq_msg_size (zmq_msg_t *msg_)
|
||||
ssize_t zmq_msg_size (zmq_msg_t *msg_)
|
||||
{
|
||||
if (!msg_) {
|
||||
errno = EFAULT;
|
||||
|
Loading…
x
Reference in New Issue
Block a user