mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-22 14:10:54 -04:00
Improvements to Comment Handling and GxsChannels.
- Added Vote dummy data into channels. - Fixed up RsGxsImage handling to avoid memory issues - need to switch to shared_ptr later. - Added "BestScore" calculations into Comments - not sure if the maths is right. - Added Hashing interface to Channels. - misc bugfixes. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6218 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
4866c5585b
commit
b9f2708927
7 changed files with 246 additions and 28 deletions
|
@ -171,7 +171,8 @@ bool RsGxsChannelGroupItem::toChannelGroup(RsGxsChannelGroup &group, bool moveIm
|
|||
if (moveImage)
|
||||
{
|
||||
group.mImage.take((uint8_t *) mImage.binData.bin_data, mImage.binData.bin_len);
|
||||
mImage.TlvShallowClear();
|
||||
// mImage doesn't have a ShallowClear at the moment!
|
||||
mImage.binData.TlvShallowClear();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -376,7 +377,8 @@ bool RsGxsChannelPostItem::toChannelPost(RsGxsChannelPost &post, bool moveImage)
|
|||
if (moveImage)
|
||||
{
|
||||
post.mThumbnail.take((uint8_t *) mThumbnail.binData.bin_data, mThumbnail.binData.bin_len);
|
||||
mThumbnail.TlvShallowClear();
|
||||
// mThumbnail doesn't have a ShallowClear at the moment!
|
||||
mThumbnail.binData.TlvShallowClear();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -392,7 +394,6 @@ bool RsGxsChannelPostItem::toChannelPost(RsGxsChannelPost &post, bool moveImage)
|
|||
fi.mName = RsDirUtil::getTopDir(fit->name);
|
||||
fi.mSize = fit->filesize;
|
||||
fi.mHash = fit->hash;
|
||||
fi.mPath = fit->path;
|
||||
|
||||
post.mFiles.push_back(fi);
|
||||
post.mCount++;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue