mirror of
https://github.com/zeromq/libzmq.git
synced 2025-10-27 19:10:22 +01:00
Silence all "unused parameter" warnings from Clang.
Compiling without warnings is a good goal, because it makes
new warnings (which probably indicate bugs) stand out rather
than getting lost in the spam.
My fixes fall into two categories:
- Adding (void) casts of unused parameters, where their
unusedness seems like a TODO (or in some cases a bug?).
- Removing parameter names altogether, where the function
is clearly a stub that will never use its parameters.
Should be no change in behavior.
This commit is contained in:
@@ -61,6 +61,9 @@ zmq::router_t::~router_t ()
|
||||
|
||||
void zmq::router_t::xattach_pipe (pipe_t *pipe_, bool icanhasall_)
|
||||
{
|
||||
// icanhasall_ is unused
|
||||
(void)icanhasall_;
|
||||
|
||||
zmq_assert (pipe_);
|
||||
|
||||
bool identity_ok = identify_peer (pipe_);
|
||||
@@ -128,6 +131,9 @@ void zmq::router_t::xwrite_activated (pipe_t *pipe_)
|
||||
|
||||
int zmq::router_t::xsend (msg_t *msg_, int flags_)
|
||||
{
|
||||
// flags_ is unused
|
||||
(void)flags_;
|
||||
|
||||
// If this is the first part of the message it's the ID of the
|
||||
// peer to send the message to.
|
||||
if (!more_out) {
|
||||
@@ -193,6 +199,9 @@ int zmq::router_t::xsend (msg_t *msg_, int flags_)
|
||||
|
||||
int zmq::router_t::xrecv (msg_t *msg_, int flags_)
|
||||
{
|
||||
// flags_ is unused
|
||||
(void)flags_;
|
||||
|
||||
if (prefetched) {
|
||||
if (!identity_sent) {
|
||||
int rc = msg_->move (prefetched_id);
|
||||
|
||||
Reference in New Issue
Block a user