From 31d39a798cd9969a9a38ddb4047bd4731f926696 Mon Sep 17 00:00:00 2001 From: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com> Date: Thu, 27 Aug 2015 14:34:36 -0400 Subject: [PATCH] build: fix some build warnings Issue: #79703 Change-Id: I403df97717df718b8931a0ecbf9f2b69053d5eb0 --- src/iax/iaxcall.h | 2 +- src/manager.cpp | 3 ++- src/ringdht/ringaccount.cpp | 6 +++--- src/sip/sipaccount.cpp | 5 +++-- 4 files changed, 9 insertions(+), 7 deletions(-) diff --git a/src/iax/iaxcall.h b/src/iax/iaxcall.h index 85affd96e1..99f69d1f6c 100644 --- a/src/iax/iaxcall.h +++ b/src/iax/iaxcall.h @@ -136,7 +136,7 @@ class IAXCall : public Call bool offhold(); //TODO: implement mute for IAX - void muteMedia(const std::string& mediaType, bool isMuted) {} + void muteMedia(const std::string& /*mediaType*/, bool /*isMuted*/) {} //TODO: implement restartMedia for IAX void restartMediaSender() override {} diff --git a/src/manager.cpp b/src/manager.cpp index 93579169ee..7f75ae71d2 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -618,7 +618,8 @@ Manager::onHoldCall(const std::string& callId) if (auto call = getCallFromCallID(callId)) { try { - if (result = call->onhold()) + result = call->onhold(); + if (result) removeAudio(*call); // Unbind calls in main buffer } catch (const VoipLinkException &e) { RING_ERR("%s", e.what()); diff --git a/src/ringdht/ringaccount.cpp b/src/ringdht/ringaccount.cpp index cc7a093092..fbcf3bd909 100644 --- a/src/ringdht/ringaccount.cpp +++ b/src/ringdht/ringaccount.cpp @@ -199,17 +199,17 @@ RingAccount::newOutgoingCall(const std::string& toUrl) auto call = weak_call.lock(); if (not call) - return false; + return; /* First step: wait for an initialized ICE transport for SIP channel */ if (ice->isFailed() or std::chrono::steady_clock::now() >= iceInitTimeout) { RING_DBG("ice init failed (or timeout)"); call->onFailure(); - return false; + return; } if (not ice->isInitialized()) - return true; + return; /* Next step: sent the ICE data to peer through DHT */ const dht::Value::Id callvid = udist(shared_this->rand_); diff --git a/src/sip/sipaccount.cpp b/src/sip/sipaccount.cpp index 83f7791e20..3e55e9d189 100644 --- a/src/sip/sipaccount.cpp +++ b/src/sip/sipaccount.cpp @@ -1425,7 +1425,7 @@ SIPAccount::getContactHeader(pjsip_transport* t) t = transport_->get(); if (!t) { RING_ERR("Transport not created yet"); - return {}; + return {nullptr, 0}; } // The transport type must be specified, in our case START_OTHER refers to stun transport @@ -1655,7 +1655,8 @@ SIPAccount::getCredentials() const } void -SIPAccount::setRegistrationState(RegistrationState state, unsigned details_code, const std::string& detail_str) +SIPAccount::setRegistrationState(RegistrationState state, unsigned details_code, + const std::string& /*detail_str*/) { std::string details_str; const pj_str_t *description = pjsip_get_status_text(details_code); -- GitLab