fixed compilation

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6042 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2012-12-26 23:15:18 +00:00
parent 447193a576
commit 8720ab968e
3 changed files with 14 additions and 11 deletions

View File

@ -304,7 +304,9 @@ bool test_bind_addr(struct sockaddr_in addr)
if (0 != (err = bind(sockfd, (struct sockaddr *) &addr, sizeof(addr))))
{
std::cerr << " Failed to Bind to Local Address!" << std::endl;
showSocketError(std::cerr);
std::string out ;
showSocketError(out) ;
std::cerr << out << std::endl;
FAILED("Couldn't Bind to socket");

View File

@ -87,8 +87,9 @@ bool test_addr_list()
/* print out the list */
std::cerr << "IpAddressList (expect variation: 192.168.2.[100-103]:7812)";
std::cerr << std::endl;
list.printIpAddressList(std::cerr);
std::cerr << std::endl;
std::string out ;
list.printIpAddressList(out) ;
std::cerr << out << std::endl;
const uint32_t expectedListSize = 4;
CHECK(list.mAddrs.size() == expectedListSize);
@ -125,8 +126,8 @@ bool test_addr_list()
/* print out the list */
std::cerr << "IpAddressList (first item to be 192.168.2.200:8812)";
std::cerr << std::endl;
list.printIpAddressList(std::cerr);
std::cerr << std::endl;
list.printIpAddressList(out) ;
std::cerr << out<< std::endl;
/* now add with the different ports */
@ -146,8 +147,8 @@ bool test_addr_list()
std::cerr << "IpAddressList (expect same Ip, but variations in port)";
std::cerr << std::endl;
list.printIpAddressList(std::cerr);
std::cerr << std::endl;
list.printIpAddressList(out) ;
std::cerr << out <<std::endl;
REPORT("pqiIpAddrList Test");

View File

@ -48,7 +48,7 @@ int main()
RsItem *item = new testRawItem ;
item->setPriorityLevel(i % nb_levels) ;
qos.in_rsItem(item) ;
qos.in_rsItem(item,item->priority_level()) ;
}
std::cerr << "QOS is filled with: " << std::endl;
qos.print() ;
@ -105,7 +105,7 @@ int main()
case 4: item->setPriorityLevel( 8 ) ; break ;
}
qos.in_rsItem(item) ;
qos.in_rsItem(item,item->priority_level()) ;
}
// Now perform stats on outputs for the 10000 first elements
@ -114,7 +114,7 @@ int main()
for(uint32_t i=0;i<10000;++i)
{
RsItem *item = qos.out_rsItem() ;
testRawItem *item = static_cast<testRawItem*>(qos.out_rsItem()) ;
hist[item->priority_level()]++ ;
delete item ;
}
@ -151,7 +151,7 @@ int main()
{
testRawItem *item = new testRawItem ;
item->setPriorityLevel(i%nb_levels) ;
qos.in_rsItem(item) ;
qos.in_rsItem(item,item->priority_level()) ;
}
// pop a random number of packets out