diff --git a/libretroshare/src/dht/p3bitdht_peernet.cc b/libretroshare/src/dht/p3bitdht_peernet.cc index d90ba58fa..5420726f8 100644 --- a/libretroshare/src/dht/p3bitdht_peernet.cc +++ b/libretroshare/src/dht/p3bitdht_peernet.cc @@ -1109,9 +1109,9 @@ int p3BitDht::minuteTick() getRelayRates(relayRead, relayWrite, relayRelayed); getDhtRates(dhtRead, dhtWrite); +#ifdef DEBUG_PEERNET_COMMON double denom = deltaT; -#ifdef DEBUG_PEERNET_COMMON std::cerr << "p3BitDht::minuteTick() "; std::cerr << "DhtRead: " << dhtRead / denom << " kB/s "; std::cerr << "DhtWrite: " << dhtWrite / denom << " kB/s "; diff --git a/libretroshare/src/ft/ftdatamultiplex.cc b/libretroshare/src/ft/ftdatamultiplex.cc index 6bbd32f30..802dbb6d3 100644 --- a/libretroshare/src/ft/ftdatamultiplex.cc +++ b/libretroshare/src/ft/ftdatamultiplex.cc @@ -495,6 +495,8 @@ bool ftDataMultiplex::recvSingleChunkCRC(const std::string& peerId, const std::s #ifdef MPLEX_DEBUG std::cerr << "ftDataMultiplex::recvSingleChunkCrc() Received crc of file " << hash << ", from peer id " << peerId << ", chunk " << chunk_number << ", crc=" << crc.toStdString() << std::endl; +#else + (void) peerId; #endif // remove this chunk from the request list as well. diff --git a/libretroshare/src/ft/ftextralist.cc b/libretroshare/src/ft/ftextralist.cc index e5de013d3..5fcca5188 100644 --- a/libretroshare/src/ft/ftextralist.cc +++ b/libretroshare/src/ft/ftextralist.cc @@ -275,7 +275,7 @@ bool ftExtraList::cleanupOldFiles() } -bool ftExtraList::cleanupEntry(std::string /*path*/, TransferRequestFlags flags) +bool ftExtraList::cleanupEntry(std::string /*path*/, TransferRequestFlags /*flags*/) { // if (flags & RS_FILE_CONFIG_CLEANUP_DELETE) // { diff --git a/libretroshare/src/pgp/pgphandler.cc b/libretroshare/src/pgp/pgphandler.cc index 1cf552d52..6a7d68c7c 100644 --- a/libretroshare/src/pgp/pgphandler.cc +++ b/libretroshare/src/pgp/pgphandler.cc @@ -1058,7 +1058,7 @@ bool PGPHandler::encryptDataBin(const PGPIdType& key_id,const void *data, const return res ; } -bool PGPHandler::decryptDataBin(const PGPIdType& key_id,const void *encrypted_data, const uint32_t encrypted_len, unsigned char *data, unsigned int *data_len) +bool PGPHandler::decryptDataBin(const PGPIdType& /*key_id*/,const void *encrypted_data, const uint32_t encrypted_len, unsigned char *data, unsigned int *data_len) { int out_length ; unsigned char *out ; diff --git a/libretroshare/src/pgp/rscertificate.cc b/libretroshare/src/pgp/rscertificate.cc index 75d7ae5fb..34a4a727b 100644 --- a/libretroshare/src/pgp/rscertificate.cc +++ b/libretroshare/src/pgp/rscertificate.cc @@ -799,7 +799,7 @@ std::string RsCertificate::toStdString_oldFormat() const return res ; } -bool RsCertificate::initFromString_oldFormat(const std::string& certstr,uint32_t& err_code) +bool RsCertificate::initFromString_oldFormat(const std::string& certstr,uint32_t& /*err_code*/) { //parse the text to get ip address try diff --git a/libretroshare/src/pqi/authgpg.cc b/libretroshare/src/pqi/authgpg.cc index b1ab91920..6eca8538a 100644 --- a/libretroshare/src/pqi/authgpg.cc +++ b/libretroshare/src/pqi/authgpg.cc @@ -509,7 +509,7 @@ bool AuthGPG::getGPGFilteredList(std::list& list,bool (*filter)(con return true ; } -static bool filter_Validity(const PGPCertificateInfo& info) { return true ; } //{ return info._validLvl >= PGPCertificateInfo::GPGME_VALIDITY_MARGINAL ; } +static bool filter_Validity(const PGPCertificateInfo& /*info*/) { return true ; } //{ return info._validLvl >= PGPCertificateInfo::GPGME_VALIDITY_MARGINAL ; } static bool filter_Accepted(const PGPCertificateInfo& info) { return info._flags & PGPCertificateInfo::PGP_CERTIFICATE_FLAG_ACCEPT_CONNEXION ; } static bool filter_OwnSigned(const PGPCertificateInfo& info) { return info._flags & PGPCertificateInfo::PGP_CERTIFICATE_FLAG_HAS_OWN_SIGNATURE ; } diff --git a/libretroshare/src/serialiser/rsbaseitems.cc b/libretroshare/src/serialiser/rsbaseitems.cc index f9e69338a..5d4a052ac 100644 --- a/libretroshare/src/serialiser/rsbaseitems.cc +++ b/libretroshare/src/serialiser/rsbaseitems.cc @@ -1371,7 +1371,6 @@ RsFileSingleChunkCrcRequest *RsFileItemSerialiser::deserialiseChunkCrcReq(void * /* skip the header */ offset += 8; - uint8_t tmp ; ok &= GetTlvString(data, *pktsize, &offset, TLV_TYPE_STR_VALUE, item->hash); // file hash ok &= getRawUInt32(data, rssize, &offset, &(item->chunk_number)); @@ -1420,7 +1419,6 @@ RsFileSingleChunkCrc *RsFileItemSerialiser::deserialiseChunkCrc(void *data, uint /* skip the header */ offset += 8; - uint8_t tmp ; ok &= GetTlvString(data, *pktsize, &offset, TLV_TYPE_STR_VALUE, item->hash); // file hash ok &= getRawUInt32(data, rssize, &offset, &(item->chunk_number)); ok &= getRawUInt32(data, rssize, &offset, &(item->check_sum.fourbytes[0])); diff --git a/libretroshare/src/services/p3chatservice.cc b/libretroshare/src/services/p3chatservice.cc index cc33e3452..bd7f8d738 100644 --- a/libretroshare/src/services/p3chatservice.cc +++ b/libretroshare/src/services/p3chatservice.cc @@ -2848,7 +2848,7 @@ void p3ChatService::cleanLobbyCaches() sendConnectionChallenge(*it) ; } -bool p3ChatService::handleTunnelRequest(const std::string& hash,const std::string& peer_id) +bool p3ChatService::handleTunnelRequest(const std::string& hash,const std::string& /*peer_id*/) { RsStackMutex stack(mChatMtx); /********** STACK LOCKED MTX ******/ @@ -2963,7 +2963,7 @@ static void printBinaryData(void *data,uint32_t size) #endif void p3ChatService::receiveTurtleData( RsTurtleGenericTunnelItem *gitem,const std::string& hash, - const std::string& virtual_peer_id,RsTurtleGenericTunnelItem::Direction direction) + const std::string& virtual_peer_id,RsTurtleGenericTunnelItem::Direction /*direction*/) { #ifdef DEBUG_DISTANT_CHAT std::cerr << "p3ChatService::receiveTurtleData(): Received turtle data. " << std::endl; diff --git a/libretroshare/src/services/p3msgservice.cc b/libretroshare/src/services/p3msgservice.cc index cb945a4c2..a6df2077c 100644 --- a/libretroshare/src/services/p3msgservice.cc +++ b/libretroshare/src/services/p3msgservice.cc @@ -1612,7 +1612,6 @@ RsMsgItem *p3MsgService::initMIRsMsg(MessageInfo &info, const std::string &to) // by the whole message serialized and binary encrypted, so as to obfuscate // all its content. // - bool enc_ok = false ; if(info.encryption_keys.find(to) != info.encryption_keys.end()) encryptMessage(info.encryption_keys[to],msg) ; @@ -1767,7 +1766,7 @@ bool p3MsgService::getDistantOfflineMessengingInvites(std::vector(gitem) ; @@ -1967,6 +1966,8 @@ void p3MsgService::receiveTurtleData(RsTurtleGenericTunnelItem *gitem,const std: std::cerr << " data = " ; printBinaryData(item->data_bytes,item->data_size) ; std::cerr << std::endl; +#else + (void) virtual_peer_id; #endif { diff --git a/libretroshare/src/turtle/turtleclientservice.h b/libretroshare/src/turtle/turtleclientservice.h index d802a6b78..7e12b7726 100644 --- a/libretroshare/src/turtle/turtleclientservice.h +++ b/libretroshare/src/turtle/turtleclientservice.h @@ -45,7 +45,7 @@ class RsTurtleClientService // The output info_string is used by the turtle router to display info about tunnels it manages. It is // not passed to the tunnel. - virtual bool handleTunnelRequest(const std::string& hash,const std::string& peer_id) { return false ; } + virtual bool handleTunnelRequest(const std::string& /*hash*/,const std::string& /*peer_id*/) { return false ; } // This method is called by the turtle router to send data that comes out of a turtle tunnel. // The turtle router stays responsible for the memory management of data. Most of the time the @@ -65,7 +65,7 @@ class RsTurtleClientService // By default (if not overloaded), the method will just free the data, as any subclass should do as well. // Note: p3turtle stays owner of the item, so the client should not delete it! // - virtual void receiveTurtleData(RsTurtleGenericTunnelItem *item,const std::string& hash,const std::string& virtual_peer_id,RsTurtleGenericTunnelItem::Direction direction) + virtual void receiveTurtleData(RsTurtleGenericTunnelItem */*item*/,const std::string& /*hash*/,const std::string& /*virtual_peer_id*/,RsTurtleGenericTunnelItem::Direction /*direction*/) { std::cerr << "!!!!!! Received Data from turtle router, but the client service is not handling it !!!!!!!!!!" << std::endl ; } @@ -75,7 +75,7 @@ class RsTurtleClientService // services might only use the generic item already provided by the turtle // router: RsTurtleGenericDataItem - virtual RsTurtleGenericTunnelItem *deserialiseItem(void *data, uint32_t size) const { return NULL ; } + virtual RsTurtleGenericTunnelItem *deserialiseItem(void */*data*/, uint32_t /*size*/) const { return NULL ; } // These methods are called by the turtle router to add/remove virtual peers when tunnels are created/deleted // diff --git a/libretroshare/src/upnp/upnphandler_miniupnp.h b/libretroshare/src/upnp/upnphandler_miniupnp.h index e734f8413..c30b3e39a 100644 --- a/libretroshare/src/upnp/upnphandler_miniupnp.h +++ b/libretroshare/src/upnp/upnphandler_miniupnp.h @@ -66,8 +66,8 @@ virtual bool getInternalAddress(struct sockaddr_in &addr); virtual bool getExternalAddress(struct sockaddr_in &addr); /* TO IMPLEMENT: New Port Forward interface to support as many ports as necessary */ -virtual bool requestPortForward(const PortForwardParams ¶ms) { return false; } -virtual bool statusPortForward(const uint32_t fwdId, PortForwardParams ¶ms) { return false; } +virtual bool requestPortForward(const PortForwardParams &/*params*/) { return false; } +virtual bool statusPortForward(const uint32_t /*fwdId*/, PortForwardParams &/*params*/) { return false; } /* Public functions - for background thread operation, * but effectively private from rest of RS, as in derived class