| 846 | |
| 847 | |
| 848 | CUpDownClient* CDownloadQueue::GetDownloadClientByIP_UDP(uint32 dwIP, uint16 nUDPPort) const |
| 849 | { |
| 850 | wxMutexLocker lock( m_mutex ); |
| 851 | |
| 852 | for ( FileQueue::size_type i = 0; i < m_filelist.size(); i++ ) { |
| 853 | const CKnownFile::SourceSet& set = m_filelist[i]->GetSourceList(); |
| 854 | |
| 855 | for ( CKnownFile::SourceSet::const_iterator it = set.begin(); it != set.end(); ++it ) { |
| 856 | if ( it->GetIP() == dwIP && it->GetUDPPort() == nUDPPort ) { |
| 857 | return it->GetClient(); |
| 858 | } |
| 859 | } |
| 860 | } |
| 861 | return NULL; |
| 862 | } |
| 863 | |
| 864 | |
| 865 | /** |
no test coverage detected