added missing function to compute serialized size

git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5_QoS@4517 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2011-08-03 12:18:02 +00:00
parent c77d95111d
commit bf82ee38bb
2 changed files with 9 additions and 3 deletions

View File

@ -61,7 +61,7 @@ pqiperson::~pqiperson()
// The PQInterface interface.
int pqiperson::SendItem(RsItem *i)
int pqiperson::SendItem(RsItem *i,uint32_t& serialized_size)
{
std::ostringstream out;
out << "pqiperson::SendItem()";
@ -72,7 +72,7 @@ int pqiperson::SendItem(RsItem *i)
#ifdef PERSON_DEBUG
std::cerr << out.str() << std::endl;
#endif
return activepqi -> SendItem(i);
return activepqi -> SendItem(i,serialized_size);
}
else
{

View File

@ -120,7 +120,13 @@ int receiveHeartbeat();
int addChildInterface(uint32_t type, pqiconnect *pqi);
// The PQInterface interface.
virtual int SendItem(RsItem *);
virtual int SendItem(RsItem *,uint32_t& serialized_size);
virtual int SendItem(RsItem *item)
{
std::cerr << "Warning pqiperson::sendItem(RsItem*) should not be called. Plz call SendItem(RsItem *,uint32_t& serialized_size) instead." << std::endl;
uint32_t serialized_size ;
return SendItem(item,serialized_size) ;
}
virtual RsItem *GetItem();
virtual int status();