mirror of
https://github.com/zeromq/libzmq.git
synced 2025-11-07 05:58:45 +01:00
Problem: local functions not declared static
Solution: add static
This commit is contained in:
@@ -63,7 +63,7 @@
|
||||
#define ZMQ_CTX_TAG_VALUE_GOOD 0xabadcafe
|
||||
#define ZMQ_CTX_TAG_VALUE_BAD 0xdeadbeef
|
||||
|
||||
int clipped_maxsocket (int max_requested_)
|
||||
static int clipped_maxsocket (int max_requested_)
|
||||
{
|
||||
if (max_requested_ >= zmq::poller_t::max_fds ()
|
||||
&& zmq::poller_t::max_fds () != -1)
|
||||
|
||||
@@ -102,7 +102,7 @@ static int do_getsockopt_curve_key (void *const optval_,
|
||||
#endif
|
||||
|
||||
template <typename T>
|
||||
int do_setsockopt (const void *const optval_,
|
||||
static int do_setsockopt (const void *const optval_,
|
||||
const size_t optvallen_,
|
||||
T *const out_value_)
|
||||
{
|
||||
@@ -176,7 +176,7 @@ do_setsockopt_string_allow_empty_relaxed (const void *const optval_,
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
int do_setsockopt_set (const void *const optval_,
|
||||
static int do_setsockopt_set (const void *const optval_,
|
||||
const size_t optvallen_,
|
||||
std::set<T> *const set_)
|
||||
{
|
||||
|
||||
@@ -89,9 +89,8 @@ typedef struct
|
||||
|
||||
// Utility functions
|
||||
|
||||
int capture (class zmq::socket_base_t *capture_,
|
||||
zmq::msg_t *msg_,
|
||||
int more_ = 0)
|
||||
static int
|
||||
capture (class zmq::socket_base_t *capture_, zmq::msg_t *msg_, int more_ = 0)
|
||||
{
|
||||
// Copy message to capture socket if any
|
||||
if (capture_) {
|
||||
@@ -109,7 +108,7 @@ int capture (class zmq::socket_base_t *capture_,
|
||||
return 0;
|
||||
}
|
||||
|
||||
int forward (class zmq::socket_base_t *from_,
|
||||
static int forward (class zmq::socket_base_t *from_,
|
||||
zmq_socket_stats_t *from_stats_,
|
||||
class zmq::socket_base_t *to_,
|
||||
zmq_socket_stats_t *to_stats_,
|
||||
@@ -184,7 +183,7 @@ static int loop_and_send_multipart_stat (zmq::socket_base_t *control_,
|
||||
return rc;
|
||||
}
|
||||
|
||||
int reply_stats (class zmq::socket_base_t *control_,
|
||||
static int reply_stats (class zmq::socket_base_t *control_,
|
||||
zmq_socket_stats_t *frontend_stats_,
|
||||
zmq_socket_stats_t *backend_stats_)
|
||||
{
|
||||
|
||||
@@ -726,7 +726,7 @@ const char *zmq_msg_gets (const zmq_msg_t *msg_, const char *property_)
|
||||
// Polling.
|
||||
|
||||
#if defined ZMQ_HAVE_POLLER
|
||||
inline int zmq_poller_poll (zmq_pollitem_t *items_, int nitems_, long timeout_)
|
||||
static int zmq_poller_poll (zmq_pollitem_t *items_, int nitems_, long timeout_)
|
||||
{
|
||||
// implement zmq_poll on top of zmq_poller
|
||||
int rc;
|
||||
|
||||
Reference in New Issue
Block a user