mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-02 06:06:10 -04:00
Merge pull request #2308 from csoler/v0.6-BugFixing_9
V0.6 bug fixing 9
This commit is contained in:
commit
dfa088acac
10 changed files with 87 additions and 52 deletions
|
@ -2039,7 +2039,7 @@ void RsGxsNetService::debugDump()
|
|||
for(ServerMsgMap::const_iterator it(mServerMsgUpdateMap.begin());it!=mServerMsgUpdateMap.end();++it)
|
||||
{
|
||||
RsGxsGrpMetaTemporaryMap::const_iterator it2 = grpMetas.find(it->first) ;
|
||||
RsGxsGrpMetaData *grpMeta = (it2 != grpMetas.end())? it2->second : NULL;
|
||||
auto grpMeta = (it2 != grpMetas.end())? it2->second : (std::shared_ptr<RsGxsGrpMetaData>()) ;
|
||||
std::string subscribe_string = (grpMeta==NULL)?"Unknown" : ((grpMeta->mSubscribeFlags & GXS_SERV::GROUP_SUBSCRIBE_SUBSCRIBED)?" Subscribed":" NOT Subscribed") ;
|
||||
|
||||
GXSNETDEBUG__G(it->first) << " Grp:" << it->first << " last local modification (secs ago): " << nice_time_stamp(time(NULL),it->second.msgUpdateTS) << ", " << subscribe_string << std::endl;
|
||||
|
@ -5368,13 +5368,14 @@ void RsGxsNetService::receiveTurtleSearchResults(TurtleRequestId req,const unsig
|
|||
#endif
|
||||
uint32_t used_size = clear_group_data_len;
|
||||
RsItem *item = RsNxsSerialiser(mServType).deserialise(clear_group_data,&used_size) ;
|
||||
RsNxsGrp *nxs_identity_grp=nullptr;
|
||||
|
||||
if(used_size < clear_group_data_len)
|
||||
{
|
||||
uint32_t remaining_size = clear_group_data_len-used_size ;
|
||||
RsItem *item2 = RsNxsSerialiser(RS_SERVICE_GXS_TYPE_GXSID).deserialise(clear_group_data+used_size,&remaining_size) ;
|
||||
|
||||
auto nxs_identity_grp = dynamic_cast<RsNxsGrp*>(item2);
|
||||
nxs_identity_grp = dynamic_cast<RsNxsGrp*>(item2);
|
||||
|
||||
if(!nxs_identity_grp)
|
||||
std::cerr << "(EE) decrypted item contains more data that cannot be deserialized as a GxsId. Unexpected!" << std::endl;
|
||||
|
|
|
@ -143,6 +143,7 @@ struct RsGxsIdGroup : RsSerializable
|
|||
rstime_t mLastUsageTS ;
|
||||
|
||||
// Not Serialised - for GUI's benefit.
|
||||
bool mPgpLinked;
|
||||
bool mPgpKnown;
|
||||
bool mIsAContact; // change that into flags one day
|
||||
RsPgpId mPgpId;
|
||||
|
|
|
@ -969,16 +969,14 @@ bool p3IdService::createIdentity(
|
|||
{
|
||||
if(!rsNotify->cachePgpPassphrase(pgpPassword))
|
||||
{
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure caching password"
|
||||
<< std::endl;
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure caching password" << std::endl;
|
||||
ret = false;
|
||||
goto LabelCreateIdentityCleanup;
|
||||
}
|
||||
|
||||
if(!rsNotify->setDisableAskPassword(true))
|
||||
{
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure disabling password user"
|
||||
<< " request" << std::endl;
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure disabling password user request" << std::endl;
|
||||
ret = false;
|
||||
goto LabelCreateIdentityCleanup;
|
||||
}
|
||||
|
@ -990,8 +988,7 @@ bool p3IdService::createIdentity(
|
|||
|
||||
if(!createIdentity(token, params))
|
||||
{
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failed creating GXS group."
|
||||
<< std::endl;
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failed creating GXS group." << std::endl;
|
||||
ret = false;
|
||||
goto LabelCreateIdentityCleanup;
|
||||
}
|
||||
|
@ -1003,16 +1000,14 @@ bool p3IdService::createIdentity(
|
|||
token, std::chrono::seconds(10), std::chrono::milliseconds(20) ))
|
||||
!= RsTokenService::COMPLETE )
|
||||
{
|
||||
RsErr() << __PRETTY_FUNCTION__ << " waitToken("<< token
|
||||
<< ") failed with: " << wtStatus << std::endl;
|
||||
RsErr() << __PRETTY_FUNCTION__ << " waitToken("<< token << ") failed with: " << wtStatus << std::endl;
|
||||
ret = false;
|
||||
goto LabelCreateIdentityCleanup;
|
||||
}
|
||||
|
||||
if(!RsGenExchange::getPublishedGroupMeta(token, meta))
|
||||
{
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure getting updated group data."
|
||||
<< std::endl;
|
||||
RsErr() << __PRETTY_FUNCTION__ << " Failure getting updated group data." << std::endl;
|
||||
ret = false;
|
||||
goto LabelCreateIdentityCleanup;
|
||||
}
|
||||
|
@ -2022,6 +2017,7 @@ bool p3IdService::getGroupData(const uint32_t &token, std::vector<RsGxsIdGroup>
|
|||
}
|
||||
|
||||
group.mIsAContact = (mContacts.find(RsGxsId(group.mMeta.mGroupId)) != mContacts.end());
|
||||
group.mPgpLinked = (!!(group.mMeta.mGroupFlags & RSGXSID_GROUPFLAG_REALID_kept_for_compatibility)) || !!(group.mMeta.mGroupFlags & RSGXSID_GROUPFLAG_REALID);
|
||||
|
||||
groups.push_back(group);
|
||||
delete(item);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue