mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-12 00:23:08 -04:00
changed post fixed operator++ into prefixed. More efficient on some systems. Patch from Phenom.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7630 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
880efee332
commit
d547cb6fdb
82 changed files with 717 additions and 718 deletions
|
@ -213,7 +213,7 @@ void AuthGPG::processServices()
|
|||
RsStackMutex stack(gpgMtxService); /******* LOCKED ******/
|
||||
|
||||
std::list<AuthGPGService*>::iterator serviceIt;
|
||||
for (serviceIt = services.begin(); serviceIt != services.end(); serviceIt++) {
|
||||
for (serviceIt = services.begin(); serviceIt != services.end(); ++serviceIt) {
|
||||
operation = (*serviceIt)->getGPGOperation();
|
||||
if (operation) {
|
||||
service = *serviceIt;
|
||||
|
@ -695,7 +695,7 @@ bool AuthGPG::loadList(std::list<RsItem*>& load)
|
|||
RsStackMutex stack(gpgMtxData); /******* LOCKED ******/
|
||||
/* load the list of accepted gpg keys */
|
||||
std::list<RsItem *>::iterator it;
|
||||
for(it = load.begin(); it != load.end(); it++)
|
||||
for(it = load.begin(); it != load.end(); ++it)
|
||||
{
|
||||
RsConfigKeyValueSet *vitem = dynamic_cast<RsConfigKeyValueSet *>(*it);
|
||||
if(vitem)
|
||||
|
@ -707,7 +707,7 @@ bool AuthGPG::loadList(std::list<RsItem*>& load)
|
|||
#endif
|
||||
|
||||
std::list<RsTlvKeyValue>::iterator kit;
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); kit++)
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); ++kit)
|
||||
if (kit->key != mOwnGpgId.toStdString())
|
||||
PGPHandler::setAcceptConnexion(RsPgpId(kit->key), (kit->value == "TRUE"));
|
||||
}
|
||||
|
|
|
@ -1633,7 +1633,7 @@ bool AuthSSLimpl::saveList(bool& cleanup, std::list<RsItem*>& lst)
|
|||
// Now save config for network digging strategies
|
||||
RsConfigKeyValueSet *vitem = new RsConfigKeyValueSet ;
|
||||
std::map<RsPeerId, sslcert*>::iterator mapIt;
|
||||
for (mapIt = mCerts.begin(); mapIt != mCerts.end(); mapIt++) {
|
||||
for (mapIt = mCerts.begin(); mapIt != mCerts.end(); ++mapIt) {
|
||||
if (mapIt->first == mOwnId) {
|
||||
continue;
|
||||
}
|
||||
|
@ -1658,7 +1658,7 @@ bool AuthSSLimpl::loadList(std::list<RsItem*>& load)
|
|||
|
||||
/* load the list of accepted gpg keys */
|
||||
std::list<RsItem *>::iterator it;
|
||||
for(it = load.begin(); it != load.end(); it++) {
|
||||
for(it = load.begin(); it != load.end(); ++it) {
|
||||
RsConfigKeyValueSet *vitem = dynamic_cast<RsConfigKeyValueSet *>(*it);
|
||||
|
||||
if(vitem) {
|
||||
|
@ -1669,7 +1669,7 @@ bool AuthSSLimpl::loadList(std::list<RsItem*>& load)
|
|||
#endif
|
||||
|
||||
std::list<RsTlvKeyValue>::iterator kit;
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); kit++) {
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); ++kit) {
|
||||
if (RsPeerId(kit->key) == mOwnId) {
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -58,7 +58,7 @@ void p3ConfigMgr::tick()
|
|||
|
||||
/* iterate through and check if any have changed */
|
||||
std::list<pqiConfig *>::iterator it;
|
||||
for(it = mConfigs.begin(); it != mConfigs.end(); it++)
|
||||
for(it = mConfigs.begin(); it != mConfigs.end(); ++it)
|
||||
{
|
||||
if ((*it)->HasConfigChanged(0))
|
||||
{
|
||||
|
@ -105,7 +105,7 @@ void p3ConfigMgr::saveConfig()
|
|||
RsStackMutex stack(cfgMtx); /***** LOCK STACK MUTEX ****/
|
||||
|
||||
std::list<pqiConfig *>::iterator it;
|
||||
for(it = mConfigs.begin(); it != mConfigs.end(); it++)
|
||||
for(it = mConfigs.begin(); it != mConfigs.end(); ++it)
|
||||
{
|
||||
if ((*it)->HasConfigChanged(1))
|
||||
{
|
||||
|
@ -133,7 +133,7 @@ void p3ConfigMgr::loadConfig()
|
|||
{
|
||||
std::list<pqiConfig *>::iterator cit;
|
||||
RsFileHash dummyHash ;
|
||||
for (cit = mConfigs.begin(); cit != mConfigs.end(); cit++)
|
||||
for (cit = mConfigs.begin(); cit != mConfigs.end(); ++cit)
|
||||
{
|
||||
#ifdef CONFIG_DEBUG
|
||||
std::cerr << "p3ConfigMgr::loadConfig() Element: ";
|
||||
|
@ -230,7 +230,7 @@ bool p3Config::loadConfig()
|
|||
#endif
|
||||
|
||||
/* bad load */
|
||||
for(it = load.begin(); it != load.end(); it++)
|
||||
for(it = load.begin(); it != load.end(); ++it)
|
||||
{
|
||||
delete (*it);
|
||||
}
|
||||
|
@ -250,7 +250,7 @@ bool p3Config::loadConfig()
|
|||
#endif
|
||||
|
||||
/* bad load */
|
||||
for(it = load.begin(); it != load.end(); it++)
|
||||
for(it = load.begin(); it != load.end(); ++it)
|
||||
{
|
||||
delete (*it);
|
||||
}
|
||||
|
@ -484,7 +484,7 @@ bool p3GeneralConfig::saveList(bool &cleanup, std::list<RsItem *>& savelist)
|
|||
|
||||
RsConfigKeyValueSet *item = new RsConfigKeyValueSet();
|
||||
std::map<std::string, std::string>::iterator it;
|
||||
for(it = settings.begin(); it != settings.end(); it++)
|
||||
for(it = settings.begin(); it != settings.end(); ++it)
|
||||
{
|
||||
RsTlvKeyValue kv;
|
||||
kv.key = it->first;
|
||||
|
@ -528,7 +528,7 @@ bool p3GeneralConfig::loadList(std::list<RsItem *>& load)
|
|||
if (item)
|
||||
{
|
||||
for(kit = item->tlvkvs.pairs.begin();
|
||||
kit != item->tlvkvs.pairs.end(); kit++)
|
||||
kit != item->tlvkvs.pairs.end(); ++kit)
|
||||
{
|
||||
settings[kit->key] = kit->value;
|
||||
}
|
||||
|
|
|
@ -218,8 +218,8 @@ bool p3HistoryMgr::saveList(bool& cleanup, std::list<RsItem*>& saveData)
|
|||
|
||||
std::map<RsPeerId, std::map<uint32_t, RsHistoryMsgItem*> >::iterator mit;
|
||||
std::map<uint32_t, RsHistoryMsgItem*>::iterator lit;
|
||||
for (mit = mMessages.begin(); mit != mMessages.end(); mit++) {
|
||||
for (lit = mit->second.begin(); lit != mit->second.end(); lit++) {
|
||||
for (mit = mMessages.begin(); mit != mMessages.end(); ++mit) {
|
||||
for (lit = mit->second.begin(); lit != mit->second.end(); ++lit) {
|
||||
if (lit->second->saveToDisc) {
|
||||
saveData.push_back(lit->second);
|
||||
}
|
||||
|
@ -284,7 +284,7 @@ bool p3HistoryMgr::loadList(std::list<RsItem*>& load)
|
|||
RsHistoryMsgItem *msgItem;
|
||||
std::list<RsItem*>::iterator it;
|
||||
|
||||
for (it = load.begin(); it != load.end(); it++) {
|
||||
for (it = load.begin(); it != load.end(); ++it) {
|
||||
if (NULL != (msgItem = dynamic_cast<RsHistoryMsgItem*>(*it))) {
|
||||
|
||||
std::map<RsPeerId, std::map<uint32_t, RsHistoryMsgItem*> >::iterator mit = mMessages.find(msgItem->chatPeerId);
|
||||
|
@ -307,7 +307,7 @@ bool p3HistoryMgr::loadList(std::list<RsItem*>& load)
|
|||
|
||||
RsConfigKeyValueSet *rskv ;
|
||||
if (NULL != (rskv = dynamic_cast<RsConfigKeyValueSet*>(*it))) {
|
||||
for (std::list<RsTlvKeyValue>::const_iterator kit = rskv->tlvkvs.pairs.begin(); kit != rskv->tlvkvs.pairs.end(); kit++) {
|
||||
for (std::list<RsTlvKeyValue>::const_iterator kit = rskv->tlvkvs.pairs.begin(); kit != rskv->tlvkvs.pairs.end(); ++kit) {
|
||||
if (kit->key == "PUBLIC_ENABLE") {
|
||||
mPublicEnable = (kit->value == "TRUE") ? true : false;
|
||||
continue;
|
||||
|
@ -398,7 +398,7 @@ bool p3HistoryMgr::getMessages(const RsPeerId &chatPeerId, std::list<HistoryMsg>
|
|||
{
|
||||
std::map<uint32_t, RsHistoryMsgItem*>::reverse_iterator lit;
|
||||
|
||||
for (lit = mit->second.rbegin(); lit != mit->second.rend(); lit++)
|
||||
for (lit = mit->second.rbegin(); lit != mit->second.rend(); ++lit)
|
||||
{
|
||||
HistoryMsg msg;
|
||||
convertMsg(lit->second, msg);
|
||||
|
@ -419,7 +419,7 @@ bool p3HistoryMgr::getMessage(uint32_t msgId, HistoryMsg &msg)
|
|||
RsStackMutex stack(mHistoryMtx); /********** STACK LOCKED MTX ******/
|
||||
|
||||
std::map<RsPeerId, std::map<uint32_t, RsHistoryMsgItem*> >::iterator mit;
|
||||
for (mit = mMessages.begin(); mit != mMessages.end(); mit++) {
|
||||
for (mit = mMessages.begin(); mit != mMessages.end(); ++mit) {
|
||||
std::map<uint32_t, RsHistoryMsgItem*>::iterator lit = mit->second.find(msgId);
|
||||
if (lit != mit->second.end()) {
|
||||
convertMsg(lit->second, msg);
|
||||
|
@ -443,7 +443,7 @@ void p3HistoryMgr::clear(const RsPeerId &chatPeerId)
|
|||
}
|
||||
|
||||
std::map<uint32_t, RsHistoryMsgItem*>::iterator lit;
|
||||
for (lit = mit->second.begin(); lit != mit->second.end(); lit++) {
|
||||
for (lit = mit->second.begin(); lit != mit->second.end(); ++lit) {
|
||||
delete(lit->second);
|
||||
}
|
||||
mit->second.clear();
|
||||
|
|
|
@ -221,7 +221,7 @@ void p3LinkMgrIMPL::getOnlineList(std::list<RsPeerId> &ssl_peers)
|
|||
RsStackMutex stack(mLinkMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::map<RsPeerId, peerConnectState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.state & RS_PEER_S_CONNECTED)
|
||||
{
|
||||
|
@ -236,7 +236,7 @@ void p3LinkMgrIMPL::getFriendList(std::list<RsPeerId> &ssl_peers)
|
|||
RsStackMutex stack(mLinkMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::map<RsPeerId, peerConnectState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
ssl_peers.push_back(it->first);
|
||||
}
|
||||
|
@ -332,7 +332,7 @@ void p3LinkMgrIMPL::statusTick()
|
|||
|
||||
RsStackMutex stack(mLinkMtx); /****** LOCK MUTEX ******/
|
||||
std::map<RsPeerId, peerConnectState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.state & RS_PEER_S_CONNECTED)
|
||||
{
|
||||
|
@ -359,7 +359,7 @@ void p3LinkMgrIMPL::statusTick()
|
|||
|
||||
#ifndef P3CONNMGR_NO_AUTO_CONNECTION
|
||||
|
||||
for(it2 = retryIds.begin(); it2 != retryIds.end(); it2++)
|
||||
for(it2 = retryIds.begin(); it2 != retryIds.end(); ++it2)
|
||||
{
|
||||
#ifdef LINKMGR_DEBUG_TICK
|
||||
std::cerr << "p3LinkMgrIMPL::statusTick() RETRY TIMEOUT for: ";
|
||||
|
@ -426,7 +426,7 @@ void p3LinkMgrIMPL::tickMonitors()
|
|||
std::cerr << "p3LinkMgrIMPL::tickMonitors() StatusChanged! List:" << std::endl;
|
||||
#endif
|
||||
/* assemble list */
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.actions)
|
||||
{
|
||||
|
@ -479,7 +479,7 @@ void p3LinkMgrIMPL::tickMonitors()
|
|||
}
|
||||
|
||||
/* do the Others as well! */
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); it++)
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); ++it)
|
||||
{
|
||||
if (it->second.actions)
|
||||
{
|
||||
|
@ -541,7 +541,7 @@ void p3LinkMgrIMPL::tickMonitors()
|
|||
|
||||
/* send to all monitors */
|
||||
std::list<pqiMonitor *>::iterator mit;
|
||||
for(mit = clients.begin(); mit != clients.end(); mit++)
|
||||
for(mit = clients.begin(); mit != clients.end(); ++mit)
|
||||
{
|
||||
(*mit)->statusChange(actionList);
|
||||
}
|
||||
|
@ -553,7 +553,7 @@ void p3LinkMgrIMPL::tickMonitors()
|
|||
|
||||
/* notify all monitors */
|
||||
std::list<pqiMonitor *>::iterator mit;
|
||||
for(mit = clients.begin(); mit != clients.end(); mit++) {
|
||||
for(mit = clients.begin(); mit != clients.end(); ++mit) {
|
||||
(*mit)->statusChanged();
|
||||
}
|
||||
|
||||
|
@ -1723,7 +1723,7 @@ bool p3LinkMgrIMPL::locked_CheckPotentialAddr(const struct sockaddr_storage &ad
|
|||
/* checks - is it the dreaded 1.0.0.0 */
|
||||
|
||||
std::list<struct sockaddr_storage>::const_iterator it;
|
||||
for(it = mBannedIpList.begin(); it != mBannedIpList.end(); it++)
|
||||
for(it = mBannedIpList.begin(); it != mBannedIpList.end(); ++it)
|
||||
{
|
||||
if (sockaddr_storage_sameip(*it, addr))
|
||||
{
|
||||
|
@ -1886,7 +1886,7 @@ void p3LinkMgrIMPL::locked_ConnectAttempt_HistoricalAddresses(peerConnectState
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
for(ait = ipAddrs.mLocal.mAddrs.begin();
|
||||
ait != ipAddrs.mLocal.mAddrs.end(); ait++)
|
||||
ait != ipAddrs.mLocal.mAddrs.end(); ++ait)
|
||||
{
|
||||
if (locked_CheckPotentialAddr(ait->mAddr, now - ait->mSeenTime))
|
||||
{
|
||||
|
@ -1913,7 +1913,7 @@ void p3LinkMgrIMPL::locked_ConnectAttempt_HistoricalAddresses(peerConnectState
|
|||
}
|
||||
|
||||
for(ait = ipAddrs.mExt.mAddrs.begin();
|
||||
ait != ipAddrs.mExt.mAddrs.end(); ait++)
|
||||
ait != ipAddrs.mExt.mAddrs.end(); ++ait)
|
||||
{
|
||||
if (locked_CheckPotentialAddr(ait->mAddr, now - ait->mSeenTime))
|
||||
{
|
||||
|
@ -2036,7 +2036,7 @@ bool p3LinkMgrIMPL::addAddressIfUnique(std::list<peerConnectAddress> &addrList,
|
|||
#endif
|
||||
|
||||
std::list<peerConnectAddress>::iterator it;
|
||||
for(it = addrList.begin(); it != addrList.end(); it++)
|
||||
for(it = addrList.begin(); it != addrList.end(); ++it)
|
||||
{
|
||||
if (sockaddr_storage_same(pca.addr, it->addr) &&
|
||||
(pca.type == it->type))
|
||||
|
@ -2213,7 +2213,7 @@ void p3LinkMgrIMPL::printPeerLists(std::ostream &out)
|
|||
|
||||
|
||||
std::map<RsPeerId, peerConnectState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
out << "\t SSL ID: " << it->second.id.toStdString();
|
||||
out << "\t State: " << it->second.state;
|
||||
|
@ -2222,7 +2222,7 @@ void p3LinkMgrIMPL::printPeerLists(std::ostream &out)
|
|||
|
||||
out << "p3LinkMgrIMPL::printPeerLists() Others List";
|
||||
out << std::endl;
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); it++)
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); ++it)
|
||||
{
|
||||
out << "\t SSL ID: " << it->second.id.toStdString();
|
||||
out << "\t State: " << it->second.state;
|
||||
|
|
|
@ -280,7 +280,7 @@ void p3NetMgrIMPL::netReset()
|
|||
std::cerr << "p3NetMgrIMPL::netReset() resetting listeners" << std::endl;
|
||||
#endif
|
||||
std::list<pqiNetListener *>::const_iterator it;
|
||||
for(it = mNetListeners.begin(); it != mNetListeners.end(); it++)
|
||||
for(it = mNetListeners.begin(); it != mNetListeners.end(); ++it)
|
||||
{
|
||||
(*it)->resetListener(iaddr);
|
||||
#ifdef NETMGR_DEBUG_RESET
|
||||
|
@ -1194,7 +1194,7 @@ void p3NetMgrIMPL::addNetAssistFirewall(uint32_t id, pqiNetAssistFirewall *fwAge
|
|||
bool p3NetMgrIMPL::enableNetAssistFirewall(bool on)
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
(it->second)->enable(on);
|
||||
}
|
||||
|
@ -1205,7 +1205,7 @@ bool p3NetMgrIMPL::enableNetAssistFirewall(bool on)
|
|||
bool p3NetMgrIMPL::netAssistFirewallEnabled()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
if ((it->second)->getEnabled())
|
||||
{
|
||||
|
@ -1218,7 +1218,7 @@ bool p3NetMgrIMPL::netAssistFirewallEnabled()
|
|||
bool p3NetMgrIMPL::netAssistFirewallActive()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
if ((it->second)->getActive())
|
||||
{
|
||||
|
@ -1231,7 +1231,7 @@ bool p3NetMgrIMPL::netAssistFirewallActive()
|
|||
bool p3NetMgrIMPL::netAssistFirewallShutdown()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
(it->second)->shutdown();
|
||||
}
|
||||
|
@ -1241,7 +1241,7 @@ bool p3NetMgrIMPL::netAssistFirewallShutdown()
|
|||
bool p3NetMgrIMPL::netAssistFirewallPorts(uint16_t iport, uint16_t eport)
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
(it->second)->setInternalPort(iport);
|
||||
(it->second)->setExternalPort(eport);
|
||||
|
@ -1253,7 +1253,7 @@ bool p3NetMgrIMPL::netAssistFirewallPorts(uint16_t iport, uint16_t eport)
|
|||
bool p3NetMgrIMPL::netAssistExtAddress(struct sockaddr_storage &extAddr)
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator it;
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); it++)
|
||||
for(it = mFwAgents.begin(); it != mFwAgents.end(); ++it)
|
||||
{
|
||||
if ((it->second)->getActive())
|
||||
{
|
||||
|
@ -1281,7 +1281,7 @@ bool p3NetMgrIMPL::enableNetAssistConnect(bool on)
|
|||
#endif
|
||||
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->enable(on);
|
||||
}
|
||||
|
@ -1291,7 +1291,7 @@ bool p3NetMgrIMPL::enableNetAssistConnect(bool on)
|
|||
bool p3NetMgrIMPL::netAssistConnectEnabled()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
if ((it->second)->getEnabled())
|
||||
{
|
||||
|
@ -1315,7 +1315,7 @@ bool p3NetMgrIMPL::netAssistConnectEnabled()
|
|||
bool p3NetMgrIMPL::netAssistConnectActive()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
if ((it->second)->getActive())
|
||||
|
||||
|
@ -1340,7 +1340,7 @@ bool p3NetMgrIMPL::netAssistConnectActive()
|
|||
bool p3NetMgrIMPL::netAssistConnectStats(uint32_t &netsize, uint32_t &localnetsize)
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
if (((it->second)->getActive()) && ((it->second)->getNetworkStats(netsize, localnetsize)))
|
||||
|
||||
|
@ -1371,7 +1371,7 @@ bool p3NetMgrIMPL::netAssistConnectShutdown()
|
|||
#endif
|
||||
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->shutdown();
|
||||
}
|
||||
|
@ -1387,7 +1387,7 @@ bool p3NetMgrIMPL::netAssistFriend(const RsPeerId &id, bool on)
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
if (on)
|
||||
(it->second)->findPeer(id);
|
||||
|
@ -1407,7 +1407,7 @@ bool p3NetMgrIMPL::netAssistKnownPeer(const RsPeerId &id, const struct sockaddr_
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->addKnownPeer(id, addr, flags);
|
||||
}
|
||||
|
@ -1423,7 +1423,7 @@ bool p3NetMgrIMPL::netAssistBadPeer(const struct sockaddr_storage &addr, uint32_
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->addBadPeer(addr, reason, flags, age);
|
||||
}
|
||||
|
@ -1440,7 +1440,7 @@ bool p3NetMgrIMPL::netAssistAttach(bool on)
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->setAttachMode(on);
|
||||
}
|
||||
|
@ -1458,7 +1458,7 @@ bool p3NetMgrIMPL::netAssistStatusUpdate(const RsPeerId &id, int state)
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->ConnectionFeedback(id, state);
|
||||
}
|
||||
|
@ -1472,7 +1472,7 @@ bool p3NetMgrIMPL::netAssistSetAddress( const struct sockaddr_storage & /*laddr*
|
|||
{
|
||||
#if 0
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->setExternalInterface(laddr, eaddr, mode);
|
||||
}
|
||||
|
@ -1483,13 +1483,13 @@ bool p3NetMgrIMPL::netAssistSetAddress( const struct sockaddr_storage & /*laddr*
|
|||
void p3NetMgrIMPL::netAssistTick()
|
||||
{
|
||||
std::map<uint32_t, pqiNetAssistConnect *>::iterator it;
|
||||
for(it = mDhts.begin(); it != mDhts.end(); it++)
|
||||
for(it = mDhts.begin(); it != mDhts.end(); ++it)
|
||||
{
|
||||
(it->second)->tick();
|
||||
}
|
||||
|
||||
std::map<uint32_t, pqiNetAssistFirewall *>::iterator fit;
|
||||
for(fit = mFwAgents.begin(); fit != mFwAgents.end(); fit++)
|
||||
for(fit = mFwAgents.begin(); fit != mFwAgents.end(); ++fit)
|
||||
{
|
||||
(fit->second)->tick();
|
||||
}
|
||||
|
|
|
@ -218,7 +218,7 @@ bool p3Notify::ClearFeedItems(uint32_t type)
|
|||
}
|
||||
else
|
||||
{
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
|
|
@ -601,7 +601,7 @@ bool p3PeerMgrIMPL::haveOnceConnected()
|
|||
|
||||
/* check for existing */
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.lastcontact > 0)
|
||||
{
|
||||
|
@ -771,7 +771,7 @@ bool p3PeerMgrIMPL::removeFriend(const RsPgpId &id)
|
|||
bool success = false;
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
//remove ssl and gpg_ids
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (find(sslid_toRemove.begin(),sslid_toRemove.end(),it->second.id) != sslid_toRemove.end())
|
||||
{
|
||||
|
@ -789,7 +789,7 @@ bool p3PeerMgrIMPL::removeFriend(const RsPgpId &id)
|
|||
}
|
||||
}
|
||||
|
||||
for(std::list<RsPeerId>::iterator rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); rit++)
|
||||
for(std::list<RsPeerId>::iterator rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); ++rit)
|
||||
if (mFriendList.end() != (it = mFriendList.find(*rit)))
|
||||
mFriendList.erase(it);
|
||||
|
||||
|
@ -804,7 +804,7 @@ bool p3PeerMgrIMPL::removeFriend(const RsPgpId &id)
|
|||
}
|
||||
|
||||
std::list<RsPeerId>::iterator rit;
|
||||
for(rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); rit++)
|
||||
for(rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); ++rit)
|
||||
{
|
||||
mLinkMgr->removeFriend(*rit);
|
||||
}
|
||||
|
@ -844,7 +844,7 @@ bool p3PeerMgrIMPL::removeFriend(const RsPeerId &id, bool removePgpId)
|
|||
bool success = false;
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
//remove ssl and gpg_ids
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.id == id)
|
||||
{
|
||||
|
@ -864,13 +864,13 @@ bool p3PeerMgrIMPL::removeFriend(const RsPeerId &id, bool removePgpId)
|
|||
}
|
||||
}
|
||||
|
||||
for(std::list<RsPeerId>::iterator rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); rit++)
|
||||
for(std::list<RsPeerId>::iterator rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); ++rit)
|
||||
if (mFriendList.end() != (it = mFriendList.find(*rit)))
|
||||
mFriendList.erase(it);
|
||||
|
||||
std::map<RsPgpId,ServicePermissionFlags>::iterator it2 ;
|
||||
|
||||
for(std::list<RsPgpId>::iterator rit = pgpid_toRemove.begin(); rit != pgpid_toRemove.end(); rit++)
|
||||
for(std::list<RsPgpId>::iterator rit = pgpid_toRemove.begin(); rit != pgpid_toRemove.end(); ++rit)
|
||||
if (mFriendsPermissionFlags.end() != (it2 = mFriendsPermissionFlags.find(*rit)))
|
||||
mFriendsPermissionFlags.erase(it2);
|
||||
|
||||
|
@ -880,7 +880,7 @@ bool p3PeerMgrIMPL::removeFriend(const RsPeerId &id, bool removePgpId)
|
|||
}
|
||||
|
||||
std::list<RsPeerId>::iterator rit;
|
||||
for(rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); rit++)
|
||||
for(rit = sslid_toRemove.begin(); rit != sslid_toRemove.end(); ++rit)
|
||||
{
|
||||
mLinkMgr->removeFriend(*rit);
|
||||
}
|
||||
|
@ -910,7 +910,7 @@ void p3PeerMgrIMPL::printPeerLists(std::ostream &out)
|
|||
|
||||
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
out << "\t SSL ID: " << it->second.id;
|
||||
out << "\t GPG ID: " << it->second.gpg_id;
|
||||
|
@ -919,7 +919,7 @@ void p3PeerMgrIMPL::printPeerLists(std::ostream &out)
|
|||
|
||||
out << "p3PeerMgrIMPL::printPeerLists() Others List";
|
||||
out << std::endl;
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); it++)
|
||||
for(it = mOthersList.begin(); it != mOthersList.end(); ++it)
|
||||
{
|
||||
out << "\t SSL ID: " << it->second.id;
|
||||
out << "\t GPG ID: " << it->second.gpg_id;
|
||||
|
@ -1529,7 +1529,7 @@ bool p3PeerMgrIMPL::saveList(bool &cleanup, std::list<RsItem *>& saveData)
|
|||
|
||||
/* iterate through all friends and save */
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
item = new RsPeerNetItem();
|
||||
item->clear();
|
||||
|
@ -1603,7 +1603,7 @@ bool p3PeerMgrIMPL::saveList(bool &cleanup, std::list<RsItem *>& saveData)
|
|||
/* save groups */
|
||||
|
||||
std::list<RsPeerGroupItem *>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
saveData.push_back(*groupIt); // no delete
|
||||
}
|
||||
|
||||
|
@ -1614,7 +1614,7 @@ void p3PeerMgrIMPL::saveDone()
|
|||
{
|
||||
/* clean up the save List */
|
||||
std::list<RsItem *>::iterator it;
|
||||
for(it = saveCleanupList.begin(); it != saveCleanupList.end(); it++)
|
||||
for(it = saveCleanupList.begin(); it != saveCleanupList.end(); ++it)
|
||||
{
|
||||
delete (*it);
|
||||
}
|
||||
|
@ -1646,7 +1646,7 @@ bool p3PeerMgrIMPL::loadList(std::list<RsItem *>& load)
|
|||
|
||||
/* load the list of peers */
|
||||
std::list<RsItem *>::iterator it;
|
||||
for(it = load.begin(); it != load.end(); it++)
|
||||
for(it = load.begin(); it != load.end(); ++it)
|
||||
{
|
||||
RsPeerNetItem *pitem = dynamic_cast<RsPeerNetItem *>(*it);
|
||||
if (pitem)
|
||||
|
@ -1717,7 +1717,7 @@ bool p3PeerMgrIMPL::loadList(std::list<RsItem *>& load)
|
|||
std::cerr << std::endl;
|
||||
#endif
|
||||
std::list<RsTlvKeyValue>::iterator kit;
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); kit++)
|
||||
for(kit = vitem->tlvkvs.pairs.begin(); kit != vitem->tlvkvs.pairs.end(); ++kit)
|
||||
{
|
||||
if (kit->key == kConfigKeyExtIpFinder)
|
||||
{
|
||||
|
@ -1799,10 +1799,10 @@ bool p3PeerMgrIMPL::loadList(std::list<RsItem *>& load)
|
|||
bool foundStandardGroup[standardGroupCount] = { false, false, false, false, false };
|
||||
|
||||
std::list<RsPeerGroupItem *>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
if ((*groupIt)->flag & RS_GROUP_FLAG_STANDARD) {
|
||||
int i;
|
||||
for (i = 0; i < standardGroupCount; i++) {
|
||||
for (i = 0; i < standardGroupCount; ++i) {
|
||||
if ((*groupIt)->id == standardGroup[i]) {
|
||||
foundStandardGroup[i] = true;
|
||||
break;
|
||||
|
@ -1822,7 +1822,7 @@ bool p3PeerMgrIMPL::loadList(std::list<RsItem *>& load)
|
|||
}
|
||||
|
||||
/* Initialize standard groups */
|
||||
for (int i = 0; i < standardGroupCount; i++) {
|
||||
for (int i = 0; i < standardGroupCount; ++i) {
|
||||
if (foundStandardGroup[i] == false) {
|
||||
RsPeerGroupItem *gitem = new RsPeerGroupItem;
|
||||
gitem->id = standardGroup[i];
|
||||
|
@ -1932,7 +1932,7 @@ bool p3PeerMgrIMPL::editGroup(const std::string &groupId, RsGroupInfo &groupInfo
|
|||
RsStackMutex stack(mPeerMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::list<RsPeerGroupItem*>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
if ((*groupIt)->id == groupId) {
|
||||
break;
|
||||
}
|
||||
|
@ -1969,7 +1969,7 @@ bool p3PeerMgrIMPL::removeGroup(const std::string &groupId)
|
|||
RsStackMutex stack(mPeerMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::list<RsPeerGroupItem*>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
if ((*groupIt)->id == groupId) {
|
||||
break;
|
||||
}
|
||||
|
@ -2004,7 +2004,7 @@ bool p3PeerMgrIMPL::getGroupInfo(const std::string &groupId, RsGroupInfo &groupI
|
|||
RsStackMutex stack(mPeerMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::list<RsPeerGroupItem*>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
if ((*groupIt)->id == groupId) {
|
||||
(*groupIt)->get(groupInfo);
|
||||
|
||||
|
@ -2020,7 +2020,7 @@ bool p3PeerMgrIMPL::getGroupInfoList(std::list<RsGroupInfo> &groupInfoList)
|
|||
RsStackMutex stack(mPeerMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::list<RsPeerGroupItem*>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
RsGroupInfo groupInfo;
|
||||
(*groupIt)->get(groupInfo);
|
||||
groupInfoList.push_back(groupInfo);
|
||||
|
@ -2046,12 +2046,12 @@ bool p3PeerMgrIMPL::assignPeersToGroup(const std::string &groupId, const std::li
|
|||
RsStackMutex stack(mPeerMtx); /****** STACK LOCK MUTEX *******/
|
||||
|
||||
std::list<RsPeerGroupItem*>::iterator groupIt;
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); groupIt++) {
|
||||
for (groupIt = groupList.begin(); groupIt != groupList.end(); ++groupIt) {
|
||||
if (groupId.empty() || (*groupIt)->id == groupId) {
|
||||
RsPeerGroupItem *groupItem = *groupIt;
|
||||
|
||||
std::list<RsPgpId>::const_iterator peerIt;
|
||||
for (peerIt = peerIds.begin(); peerIt != peerIds.end(); peerIt++) {
|
||||
for (peerIt = peerIds.begin(); peerIt != peerIds.end(); ++peerIt) {
|
||||
std::list<RsPgpId>::iterator peerIt1 = std::find(groupItem->pgpList.ids.begin(), groupItem->pgpList.ids.end(), *peerIt);
|
||||
if (assign) {
|
||||
if (peerIt1 == groupItem->pgpList.ids.end()) {
|
||||
|
@ -2148,7 +2148,7 @@ bool p3PeerMgrIMPL::removeAllFriendLocations(const RsPgpId &gpgid)
|
|||
}
|
||||
|
||||
std::list<RsPeerId>::iterator it;
|
||||
for(it = sslIds.begin(); it != sslIds.end(); it++)
|
||||
for(it = sslIds.begin(); it != sslIds.end(); ++it)
|
||||
{
|
||||
removeFriend(*it, true);
|
||||
}
|
||||
|
@ -2167,7 +2167,7 @@ bool p3PeerMgrIMPL::getAssociatedPeers(const RsPgpId &gpg_id, std::list<RsPeerId
|
|||
|
||||
int count = 0;
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (it->second.gpg_id == gpg_id)
|
||||
{
|
||||
|
@ -2212,7 +2212,7 @@ bool p3PeerMgrIMPL::removeUnusedLocations()
|
|||
time_t now = time(NULL);
|
||||
|
||||
std::map<RsPeerId, peerState>::iterator it;
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); it++)
|
||||
for(it = mFriendList.begin(); it != mFriendList.end(); ++it)
|
||||
{
|
||||
if (now - it->second.lastcontact > VERY_OLD_PEER)
|
||||
{
|
||||
|
@ -2238,7 +2238,7 @@ bool p3PeerMgrIMPL::removeUnusedLocations()
|
|||
}
|
||||
std::list<RsPeerId>::iterator it;
|
||||
|
||||
for(it = toRemove.begin(); it != toRemove.end(); it++)
|
||||
for(it = toRemove.begin(); it != toRemove.end(); ++it)
|
||||
{
|
||||
removeFriend(*it,false);
|
||||
}
|
||||
|
|
|
@ -152,7 +152,7 @@ void p3ServiceControl::getServiceChanges(std::set<RsPeerId> &updateSet)
|
|||
#endif
|
||||
|
||||
std::set<RsPeerId>::iterator it;
|
||||
for (it = mUpdatedSet.begin(); it != mUpdatedSet.end(); it++)
|
||||
for (it = mUpdatedSet.begin(); it != mUpdatedSet.end(); ++it)
|
||||
{
|
||||
updateSet.insert(*it);
|
||||
}
|
||||
|
@ -189,7 +189,7 @@ bool p3ServiceControl::getServicesAllowed(const RsPeerId &peerId, RsPeerServiceI
|
|||
|
||||
// For each registered Service.. check if peer has permissions.
|
||||
std::map<uint32_t, RsServiceInfo>::iterator it;
|
||||
for(it = mOwnServices.begin(); it != mOwnServices.end(); it++)
|
||||
for(it = mOwnServices.begin(); it != mOwnServices.end(); ++it)
|
||||
{
|
||||
if (peerHasPermissionForService_locked(peerId, it->first))
|
||||
{
|
||||
|
@ -317,7 +317,7 @@ bool p3ServiceControl::updateServicePermissions(uint32_t serviceId, const RsServ
|
|||
std::list<RsPeerId>::const_iterator pit;
|
||||
if (it != mServicePermissionMap.end())
|
||||
{
|
||||
for(pit = onlinePeers.begin(); pit != onlinePeers.end(); pit++)
|
||||
for(pit = onlinePeers.begin(); pit != onlinePeers.end(); ++pit)
|
||||
{
|
||||
if (it->second.peerHasPermission(*pit) !=
|
||||
permissions.peerHasPermission(*pit))
|
||||
|
@ -526,18 +526,18 @@ bool p3ServiceControl::updateAllFilters_locked()
|
|||
std::set<RsPeerId>::const_iterator pit;
|
||||
|
||||
std::map<RsPeerId, RsPeerServiceInfo>::const_iterator it;
|
||||
for(it = mServicesProvided.begin(); it != mServicesProvided.end(); it++)
|
||||
for(it = mServicesProvided.begin(); it != mServicesProvided.end(); ++it)
|
||||
{
|
||||
peerSet.insert(it->first);
|
||||
}
|
||||
|
||||
std::map<RsPeerId, ServicePeerFilter>::const_iterator fit;
|
||||
for(fit = mPeerFilterMap.begin(); fit != mPeerFilterMap.end(); fit++)
|
||||
for(fit = mPeerFilterMap.begin(); fit != mPeerFilterMap.end(); ++fit)
|
||||
{
|
||||
peerSet.insert(fit->first);
|
||||
}
|
||||
|
||||
for(pit = peerSet.begin(); pit != peerSet.end(); pit++)
|
||||
for(pit = peerSet.begin(); pit != peerSet.end(); ++pit)
|
||||
{
|
||||
updateFilterByPeer_locked(*pit);
|
||||
}
|
||||
|
@ -618,8 +618,8 @@ bool p3ServiceControl::updateFilterByPeer_locked(const RsPeerId &peerId)
|
|||
peerFilter.mAllowedServices.insert(oit->first);
|
||||
}
|
||||
}
|
||||
oit++;
|
||||
tit++;
|
||||
++oit;
|
||||
++tit;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -629,7 +629,7 @@ bool p3ServiceControl::updateFilterByPeer_locked(const RsPeerId &peerId)
|
|||
std::cerr << "\tSkipping Only Own Service ID: " << oit->first;
|
||||
std::cerr << std::endl;
|
||||
#endif
|
||||
oit++;
|
||||
++oit;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -637,7 +637,7 @@ bool p3ServiceControl::updateFilterByPeer_locked(const RsPeerId &peerId)
|
|||
std::cerr << "\tSkipping Only Peer Service ID: " << tit->first;
|
||||
std::cerr << std::endl;
|
||||
#endif
|
||||
tit++;
|
||||
++tit;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -735,7 +735,7 @@ void p3ServiceControl::recordFilterChanges_locked(const RsPeerId &peerId,
|
|||
}
|
||||
|
||||
// Handle the unfinished Set.
|
||||
for(; it1 != eit1; it1++)
|
||||
for(; it1 != eit1; ++it1)
|
||||
{
|
||||
#ifdef SERVICECONTROL_DEBUG
|
||||
std::cerr << "Removed Service: " << *it1;
|
||||
|
@ -746,7 +746,7 @@ void p3ServiceControl::recordFilterChanges_locked(const RsPeerId &peerId,
|
|||
filterChangeRemoved_locked(peerId, *it1);
|
||||
}
|
||||
|
||||
for(; it2 != eit2; it2++)
|
||||
for(; it2 != eit2; ++it2)
|
||||
{
|
||||
#ifdef SERVICECONTROL_DEBUG
|
||||
std::cerr << "Added Service: " << *it2;
|
||||
|
@ -761,7 +761,7 @@ void p3ServiceControl::recordFilterChanges_locked(const RsPeerId &peerId,
|
|||
#if 0
|
||||
// now we to store for later notifications.
|
||||
std::map<uint32_t, bool>::const_iterator cit;
|
||||
for(cit = changes.begin(); cit != changes.end(); cit++)
|
||||
for(cit = changes.begin(); cit != changes.end(); ++cit)
|
||||
{
|
||||
ServiceNotifications ¬es = mNotifications[cit->first];
|
||||
if (cit->second)
|
||||
|
@ -988,7 +988,7 @@ void p3ServiceControl::statusChange(const std::list<pqipeer> &plist)
|
|||
#endif
|
||||
|
||||
std::list<pqipeer>::const_iterator pit;
|
||||
for(pit = plist.begin(); pit != plist.end(); pit++)
|
||||
for(pit = plist.begin(); pit != plist.end(); ++pit)
|
||||
{
|
||||
#ifdef SERVICECONTROL_DEBUG
|
||||
std::cerr << "p3ServiceControl::statusChange() for peer: ";
|
||||
|
@ -1111,7 +1111,7 @@ void p3ServiceControl::notifyAboutFriends()
|
|||
RsStackMutex stack(mMonitorMtx); /***** LOCK STACK MUTEX ****/
|
||||
|
||||
std::multimap<uint32_t, pqiServiceMonitor *>::const_iterator sit;
|
||||
for(sit = mMonitors.begin(); sit != mMonitors.end(); sit++)
|
||||
for(sit = mMonitors.begin(); sit != mMonitors.end(); ++sit)
|
||||
{
|
||||
sit->second->statusChange(friendNotifications);
|
||||
}
|
||||
|
@ -1143,7 +1143,7 @@ void p3ServiceControl::notifyServices()
|
|||
|
||||
std::map<uint32_t, ServiceNotifications>::const_iterator it;
|
||||
std::multimap<uint32_t, pqiServiceMonitor *>::const_iterator sit, eit;
|
||||
for(it = notifications.begin(); it != notifications.end(); it++)
|
||||
for(it = notifications.begin(); it != notifications.end(); ++it)
|
||||
{
|
||||
#ifdef SERVICECONTROL_DEBUG
|
||||
std::cerr << "p3ServiceControl::notifyServices(): Notifications for Service: " << it->first;
|
||||
|
@ -1166,7 +1166,7 @@ void p3ServiceControl::notifyServices()
|
|||
std::list<pqiServicePeer> peers;
|
||||
std::set<RsPeerId>::const_iterator pit;
|
||||
for(pit = it->second.mAdded.begin();
|
||||
pit != it->second.mAdded.end(); pit++)
|
||||
pit != it->second.mAdded.end(); ++pit)
|
||||
{
|
||||
pqiServicePeer peer;
|
||||
peer.id = *pit;
|
||||
|
@ -1181,7 +1181,7 @@ void p3ServiceControl::notifyServices()
|
|||
}
|
||||
|
||||
for(pit = it->second.mRemoved.begin();
|
||||
pit != it->second.mRemoved.end(); pit++)
|
||||
pit != it->second.mRemoved.end(); ++pit)
|
||||
{
|
||||
pqiServicePeer peer;
|
||||
peer.id = *pit;
|
||||
|
@ -1195,7 +1195,7 @@ void p3ServiceControl::notifyServices()
|
|||
#endif
|
||||
}
|
||||
|
||||
for(; sit != eit; sit++)
|
||||
for(; sit != eit; ++sit)
|
||||
{
|
||||
#ifdef SERVICECONTROL_DEBUG
|
||||
std::cerr << "p3ServiceControl::notifyServices(): Sending to Monitoring Service";
|
||||
|
@ -1273,7 +1273,7 @@ std::ostream &operator<<(std::ostream &out, const RsPeerServiceInfo &info)
|
|||
out << "RsPeerServiceInfo(" << info.mPeerId << ")";
|
||||
out << std::endl;
|
||||
std::map<uint32_t, RsServiceInfo>::const_iterator it;
|
||||
for(it = info.mServiceList.begin(); it != info.mServiceList.end(); it++)
|
||||
for(it = info.mServiceList.begin(); it != info.mServiceList.end(); ++it)
|
||||
{
|
||||
out << "\t Service:" << it->first << " : ";
|
||||
out << it->second;
|
||||
|
@ -1297,7 +1297,7 @@ std::ostream &operator<<(std::ostream &out, const ServicePeerFilter &filter)
|
|||
out << " AllowAll: " << filter.mAllowAll;
|
||||
out << " Matched Services: ";
|
||||
std::set<uint32_t>::const_iterator it;
|
||||
for(it = filter.mAllowedServices.begin(); it != filter.mAllowedServices.end(); it++)
|
||||
for(it = filter.mAllowedServices.begin(); it != filter.mAllowedServices.end(); ++it)
|
||||
{
|
||||
out << *it << " ";
|
||||
}
|
||||
|
|
|
@ -70,7 +70,7 @@ int pqihandler::tick()
|
|||
|
||||
// tick all interfaces...
|
||||
std::map<RsPeerId, SearchModule *>::iterator it;
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
if (0 < ((it -> second) -> pqi) -> tick())
|
||||
{
|
||||
|
@ -120,7 +120,7 @@ int pqihandler::status()
|
|||
std::string out = "pqihandler::status() Active Modules:\n";
|
||||
|
||||
// display all interfaces...
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
rs_sprintf_append(out, "\tModule [%s] Pointer <%p>", it -> first.toStdString().c_str(), (void *) ((it -> second) -> pqi));
|
||||
}
|
||||
|
@ -131,7 +131,7 @@ int pqihandler::status()
|
|||
|
||||
|
||||
// status all interfaces...
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
((it -> second) -> pqi) -> status();
|
||||
}
|
||||
|
@ -183,7 +183,7 @@ bool pqihandler::RemoveSearchModule(SearchModule *mod)
|
|||
{
|
||||
RsStackMutex stack(coreMtx); /**************** LOCKED MUTEX ****************/
|
||||
std::map<RsPeerId, SearchModule *>::iterator it;
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
if (mod == it -> second)
|
||||
{
|
||||
|
@ -314,7 +314,7 @@ int pqihandler::locked_GetItems()
|
|||
int count = 0;
|
||||
|
||||
// loop through modules....
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
|
||||
|
@ -441,7 +441,7 @@ int pqihandler::ExtractRates(std::map<RsPeerId, RsBwRates> &ratemap, RsBwRat
|
|||
RsStackMutex stack(coreMtx); /**************** LOCKED MUTEX ****************/
|
||||
|
||||
std::map<RsPeerId, SearchModule *>::iterator it;
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
|
||||
|
@ -481,7 +481,7 @@ int pqihandler::UpdateRates()
|
|||
int effectiveDownloadsSm = 0;
|
||||
// loop through modules to get the used bandwith and the number of modules that are affectively transfering
|
||||
//std::cerr << " Looping through modules" << std::endl;
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
float crate_in = mod -> pqi -> getRate(true);
|
||||
|
@ -528,7 +528,7 @@ int pqihandler::UpdateRates()
|
|||
rate_out_modifier = - 0.001 * avail_out;
|
||||
}
|
||||
if (rate_out_modifier != 0) {
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
mod -> pqi -> setMaxRate(false, mod -> pqi -> getMaxRate(false) + rate_out_modifier);
|
||||
|
@ -543,7 +543,7 @@ int pqihandler::UpdateRates()
|
|||
rate_in_modifier = - 0.001 * avail_in;
|
||||
}
|
||||
if (rate_in_modifier != 0) {
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
mod -> pqi -> setMaxRate(true, mod -> pqi -> getMaxRate(true) + rate_in_modifier);
|
||||
|
@ -551,7 +551,7 @@ int pqihandler::UpdateRates()
|
|||
}
|
||||
|
||||
//cap the rates
|
||||
for(it = mods.begin(); it != mods.end(); it++)
|
||||
for(it = mods.begin(); it != mods.end(); ++it)
|
||||
{
|
||||
SearchModule *mod = (it -> second);
|
||||
if (mod -> pqi -> getMaxRate(false) < max_out_effective) {
|
||||
|
|
|
@ -94,7 +94,7 @@ bool pqiIpAddrList::updateIpAddressList(const pqiIpAddress &addr)
|
|||
return false;
|
||||
}
|
||||
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); it++)
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); ++it)
|
||||
{
|
||||
if (it->sameAddress(addr))
|
||||
{
|
||||
|
@ -124,7 +124,7 @@ bool pqiIpAddrList::updateIpAddressList(const pqiIpAddress &addr)
|
|||
|
||||
// ordered by decreaseing time. (newest at front)
|
||||
bool added = false;
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); it++)
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); ++it)
|
||||
{
|
||||
if (it->mSeenTime < addr.mSeenTime)
|
||||
{
|
||||
|
@ -198,7 +198,7 @@ void pqiIpAddrList::printIpAddressList(std::string &out) const
|
|||
{
|
||||
std::list<pqiIpAddress>::const_iterator it;
|
||||
time_t now = time(NULL);
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); it++)
|
||||
for(it = mAddrs.begin(); it != mAddrs.end(); ++it)
|
||||
{
|
||||
out += sockaddr_storage_tostring(it->mAddr);
|
||||
rs_sprintf_append(out, "( %ld old)\n", now - it->mSeenTime);
|
||||
|
@ -226,7 +226,7 @@ bool pqiIpAddrSet::updateAddrs(const pqiIpAddrSet &addrs)
|
|||
|
||||
bool newAddrs = false;
|
||||
std::list<pqiIpAddress>::const_iterator it;
|
||||
for(it = addrs.mLocal.mAddrs.begin(); it != addrs.mLocal.mAddrs.end(); it++)
|
||||
for(it = addrs.mLocal.mAddrs.begin(); it != addrs.mLocal.mAddrs.end(); ++it)
|
||||
{
|
||||
if (mLocal.updateIpAddressList(*it))
|
||||
{
|
||||
|
@ -238,7 +238,7 @@ bool pqiIpAddrSet::updateAddrs(const pqiIpAddrSet &addrs)
|
|||
}
|
||||
}
|
||||
|
||||
for(it = addrs.mExt.mAddrs.begin(); it != addrs.mExt.mAddrs.end(); it++)
|
||||
for(it = addrs.mExt.mAddrs.begin(); it != addrs.mExt.mAddrs.end(); ++it)
|
||||
{
|
||||
if (mExt.updateIpAddressList(*it))
|
||||
{
|
||||
|
|
|
@ -171,7 +171,7 @@ bool getLocalInterfaces_ipv4(struct in_addr &/*routeAddr*/, std::list<struct in_
|
|||
}
|
||||
|
||||
// loop through the interfaces.
|
||||
for(; ifptr->if_index != 0; ifptr++)
|
||||
for(; ifptr->if_index != 0; ++ifptr)
|
||||
{
|
||||
//copy in the interface name to look up address of
|
||||
strncpy(ifreq.ifr_name, ifptr->if_name, IF_NAMESIZE);
|
||||
|
@ -598,7 +598,7 @@ bool getPreferredInterface_ipv4(in_addr &routeAddr, struct in_addr &prefAddr) /
|
|||
std::cerr << "getPreferredInterface() " << addrs.size() << " interfaces." << std::endl;
|
||||
#endif
|
||||
|
||||
for(it = addrs.begin(); it != addrs.end(); it++)
|
||||
for(it = addrs.begin(); it != addrs.end(); ++it)
|
||||
{
|
||||
struct in_addr addr = *it;
|
||||
|
||||
|
@ -741,7 +741,7 @@ bool getLocalInterfaces(struct sockaddr_storage &existAddr, std::list<struct soc
|
|||
if (getLocalInterfaces_ipv4(existing_addr, local_addrs))
|
||||
{
|
||||
std::list<struct in_addr>::iterator it;
|
||||
for(it = local_addrs.begin(); it != local_addrs.end(); it++)
|
||||
for(it = local_addrs.begin(); it != local_addrs.end(); ++it)
|
||||
{
|
||||
/* store into prefAddr */
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ pqiperson::~pqiperson()
|
|||
|
||||
// clean up the children.
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
pqiconnect *pc = (it->second);
|
||||
delete pc;
|
||||
|
@ -180,7 +180,7 @@ int pqiperson::tick()
|
|||
|
||||
// tick the children.
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
if (0 < (it->second) -> tick())
|
||||
{
|
||||
|
@ -271,7 +271,7 @@ int pqiperson::handleNotifyEvent_locked(NetInterface *ni, int newState, const s
|
|||
|
||||
/* start again */
|
||||
int i = 0;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
std::string out;
|
||||
rs_sprintf(out, "pqiperson::connectattempt() Kid# %d of %u\n", i, kids.size());
|
||||
|
@ -328,7 +328,7 @@ int pqiperson::handleNotifyEvent_locked(NetInterface *ni, int newState, const s
|
|||
activepqi->start(); // STARTUP THREAD.
|
||||
|
||||
/* reset all other children? (clear up long UDP attempt) */
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
if (!(it->second)->thisNetInterface(ni))
|
||||
{
|
||||
|
@ -397,7 +397,7 @@ int pqiperson::reset_locked()
|
|||
pqioutput(PQL_WARNING, pqipersonzone, "pqiperson::reset() resetting all pqiconnect for Id: " + PeerId().toStdString());
|
||||
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
(it->second) -> stop(); // STOP THREAD.
|
||||
(it->second) -> reset();
|
||||
|
@ -417,7 +417,7 @@ int pqiperson::fullstopthreads()
|
|||
pqioutput(PQL_WARNING, pqipersonzone, "pqiperson::fullstopthreads() for Id: " + PeerId().toStdString());
|
||||
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
(it->second) -> fullstop(); // WAIT FOR THREAD TO STOP.
|
||||
}
|
||||
|
@ -456,7 +456,7 @@ int pqiperson::listen()
|
|||
if (!active)
|
||||
{
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
// set them all listening.
|
||||
(it->second) -> listen();
|
||||
|
@ -473,7 +473,7 @@ int pqiperson::stoplistening()
|
|||
pqioutput(PQL_DEBUG_BASIC, pqipersonzone, "pqiperson::stoplistening() Id: " + PeerId().toStdString());
|
||||
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
// set them all listening.
|
||||
(it->second) -> stoplistening();
|
||||
|
@ -640,7 +640,7 @@ void pqiperson::setMaxRate(bool in, float val)
|
|||
PQInterface::setMaxRate(in, val);
|
||||
// clean up the children.
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
(it->second) -> setMaxRate(in, val);
|
||||
}
|
||||
|
@ -675,7 +675,7 @@ void pqiperson::setRateCap_locked(float val_in, float val_out)
|
|||
PQInterface::setRateCap(val_in, val_out);
|
||||
// clean up the children.
|
||||
std::map<uint32_t, pqiconnect *>::iterator it;
|
||||
for(it = kids.begin(); it != kids.end(); it++)
|
||||
for(it = kids.begin(); it != kids.end(); ++it)
|
||||
{
|
||||
(it->second) -> setRateCap(val_in, val_out);
|
||||
}
|
||||
|
|
|
@ -272,7 +272,7 @@ void pqipersongrp::statusChange(const std::list<pqipeer> &plist)
|
|||
|
||||
/* iterate through, only worry about the friends */
|
||||
std::list<pqipeer>::const_iterator it;
|
||||
for(it = plist.begin(); it != plist.end(); it++)
|
||||
for(it = plist.begin(); it != plist.end(); ++it)
|
||||
{
|
||||
if (it->state & RS_PEER_S_FRIEND)
|
||||
{
|
||||
|
@ -339,7 +339,7 @@ void pqipersongrp::statusChanged()
|
|||
|
||||
/* count connection attempts */
|
||||
std::list<RsPeerId>::iterator peer;
|
||||
for (peer = peers.begin(); peer != peers.end(); peer++) {
|
||||
for (peer = peers.begin(); peer != peers.end(); ++peer) {
|
||||
peerConnectState state;
|
||||
if (mLinkMgr->getFriendNetStatus(*peer, state) == false) {
|
||||
continue;
|
||||
|
@ -383,7 +383,7 @@ void pqipersongrp::statusChanged()
|
|||
} /* UNLOCKED */
|
||||
|
||||
std::list<RsPeerId>::iterator cit;
|
||||
for(cit = toConnect.begin(); cit != toConnect.end(); cit++)
|
||||
for(cit = toConnect.begin(); cit != toConnect.end(); ++cit)
|
||||
{
|
||||
connectPeer(*cit, true);
|
||||
}
|
||||
|
|
|
@ -182,7 +182,7 @@ int p3ServiceServer::tick()
|
|||
std::map<uint32_t, pqiService *>::iterator it;
|
||||
|
||||
// from the beginning to where we started.
|
||||
for(it = services.begin();it != services.end(); it++)
|
||||
for(it = services.begin();it != services.end(); ++it)
|
||||
{
|
||||
|
||||
#ifdef SERVICE_DEBUG
|
||||
|
|
|
@ -563,7 +563,7 @@ int pqissllistenbase::continueaccepts()
|
|||
incoming_ssl.erase(itd);
|
||||
}
|
||||
else
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
@ -614,7 +614,7 @@ int pqissllistenbase::finaliseAccepts()
|
|||
{
|
||||
pqioutput(PQL_DEBUG_BASIC, pqissllistenzone,
|
||||
"pqissllistenbase::finaliseAccepts() SSL Connection Status Unknown");
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
|
@ -695,7 +695,7 @@ int pqissllistener::addlistenaddr(const RsPeerId& id, pqissl *acc)
|
|||
std::map<RsPeerId, pqissl *>::iterator it;
|
||||
|
||||
std::string out = "Adding to Cert Listening Addresses Id: " + id.toStdString() + "\nCurrent Certs:\n";
|
||||
for(it = listenaddr.begin(); it != listenaddr.end(); it++)
|
||||
for(it = listenaddr.begin(); it != listenaddr.end(); ++it)
|
||||
{
|
||||
out += id.toStdString() + "\n";
|
||||
if (it -> first == id)
|
||||
|
@ -722,7 +722,7 @@ int pqissllistener::removeListenPort(const RsPeerId& id)
|
|||
//
|
||||
// check if in list.
|
||||
std::map<RsPeerId, pqissl *>::iterator it;
|
||||
for(it = listenaddr.begin();it!=listenaddr.end();it++)
|
||||
for(it = listenaddr.begin();it!=listenaddr.end(); ++it)
|
||||
{
|
||||
if (it->first == id)
|
||||
{
|
||||
|
@ -750,7 +750,7 @@ int pqissllistener::status()
|
|||
std::string out = "pqissllistener::status(): Listening (";
|
||||
out += sockaddr_storage_tostring(laddr);
|
||||
out += ") for Certs:";
|
||||
for(it = listenaddr.begin(); it != listenaddr.end(); it++)
|
||||
for(it = listenaddr.begin(); it != listenaddr.end(); ++it)
|
||||
{
|
||||
out += "\n" + it -> first.toStdString() ;
|
||||
}
|
||||
|
@ -816,7 +816,7 @@ int pqissllistener::completeConnection(int fd, IncomingSSLInfo& info)
|
|||
}
|
||||
else
|
||||
{
|
||||
it++;
|
||||
++it;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -389,12 +389,12 @@ bool pqiSSLstore::encryptedSendItems(const std::list<RsItem*>& rsItemList)
|
|||
uint32_t offset = 0;
|
||||
char* data = NULL;
|
||||
|
||||
for(it = rsItemList.begin(); it != rsItemList.end(); it++)
|
||||
for(it = rsItemList.begin(); it != rsItemList.end(); ++it)
|
||||
sizeItems += rsSerialiser->size(*it);
|
||||
|
||||
data = new char[sizeItems];
|
||||
|
||||
for(it = rsItemList.begin(); it != rsItemList.end(); it++)
|
||||
for(it = rsItemList.begin(); it != rsItemList.end(); ++it)
|
||||
{
|
||||
sizeItem = rsSerialiser->size(*it);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue