mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-08-03 03:36:58 -04:00
switched RsNxsItems to new serialization
This commit is contained in:
parent
f6e59f7dee
commit
3c20a85335
3 changed files with 223 additions and 235 deletions
|
@ -3500,10 +3500,10 @@ bool RsGxsNetService::encryptSingleNxsItem(RsNxsItem *item, const RsGxsCircleId&
|
|||
#ifdef NXS_NET_DEBUG_7
|
||||
GXSNETDEBUG_P_ (item->PeerId()) << " Encrypting..." << std::endl;
|
||||
#endif
|
||||
uint32_t size = item->serial_size() ;
|
||||
uint32_t size = RsNxsSerialiser(mServType).size(item) ;
|
||||
RsTemporaryMemory tempmem( size ) ;
|
||||
|
||||
if(!item->serialise(tempmem,size))
|
||||
if(!RsNxsSerialiser(mServType).serialise(item,tempmem,&size))
|
||||
{
|
||||
std::cerr << " (EE) Cannot serialise item. Something went wrong." << std::endl;
|
||||
status = RS_NXS_ITEM_ENCRYPTION_STATUS_SERIALISATION_ERROR ;
|
||||
|
@ -3530,7 +3530,7 @@ bool RsGxsNetService::encryptSingleNxsItem(RsNxsItem *item, const RsGxsCircleId&
|
|||
enc_item->transactionNumber = item->transactionNumber ;
|
||||
enc_item->PeerId(item->PeerId()) ;
|
||||
|
||||
encrypted_item = enc_item ;
|
||||
encrypted_item = enc_item ;
|
||||
#ifdef NXS_NET_DEBUG_7
|
||||
GXSNETDEBUG_P_(item->PeerId()) << " encrypted item of size " << encrypted_len << std::endl;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue