merge of QoS branch into trunk

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4588 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2011-09-04 20:01:30 +00:00
parent 663ce50630
commit 0ed60eaf86
23 changed files with 734 additions and 337 deletions

View file

@ -33,6 +33,7 @@
#define RSSERIAL_DEBUG 1
#define CHAT_DEBUG 1
***/
#define CHAT_DEBUG 1
#include <iostream>
@ -244,6 +245,10 @@ bool RsChatMsgItem::serialise(void *data, uint32_t& pktsize)
std::cerr << "computed size: " << 256*((unsigned char*)data)[6]+((unsigned char*)data)[7] << std::endl ;
#endif
std::cerr << "Serialization result: " ;
for(int i=0;i<20;++i)
std::cerr << (int)((uint8_t*)data)[i] << " " ;
std::cerr << std::endl ;
return ok;
}
@ -379,6 +384,11 @@ RsChatMsgItem::RsChatMsgItem(void *data,uint32_t /*size*/)
uint32_t rssize = getRsItemSize(data);
bool ok = true ;
std::cerr << "Received packet result: " ;
for(int i=0;i<20;++i)
std::cerr << (int)((uint8_t*)data)[i] << " " ;
std::cerr << std::endl ;
/* get mandatory parts first */
ok &= getRawUInt32(data, rssize, &offset, &chatFlags);
ok &= getRawUInt32(data, rssize, &offset, &sendTime);