Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
577564e6
Commit
577564e6
authored
1 year ago
by
Sébastien Blin
Browse files
Options
Downloads
Patches
Plain Diff
contacts: remove unlocked saveTrustRequests
GitLab:
#942
Change-Id: Ifdd50fc15695123f5ec41cb3eabb3a23b79e85dc
parent
387d4eeb
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/jamidht/account_manager.cpp
+0
-2
0 additions, 2 deletions
src/jamidht/account_manager.cpp
src/jamidht/contact_list.cpp
+1
-0
1 addition, 0 deletions
src/jamidht/contact_list.cpp
src/jamidht/contact_list.h
+3
-3
3 additions, 3 deletions
src/jamidht/contact_list.h
with
4 additions
and
5 deletions
src/jamidht/account_manager.cpp
+
0
−
2
View file @
577564e6
...
@@ -103,7 +103,6 @@ AccountManager::onSyncData(DeviceSync&& sync, bool checkDevice)
...
@@ -103,7 +103,6 @@ AccountManager::onSyncData(DeviceSync&& sync, bool checkDevice)
false
,
false
,
tr
.
second
.
conversationId
,
tr
.
second
.
conversationId
,
{});
{});
info_
->
contacts
->
saveTrustRequests
();
}
}
dht
::
crypto
::
Identity
dht
::
crypto
::
Identity
...
@@ -359,7 +358,6 @@ AccountManager::startSync(const OnNewDeviceCb& cb, const OnDeviceAnnouncedCb& dc
...
@@ -359,7 +358,6 @@ AccountManager::startSync(const OnNewDeviceCb& cb, const OnDeviceAnnouncedCb& dc
JAMI_WARNING
(
"Accept with old convId: {}"
,
conversationId
);
JAMI_WARNING
(
"Accept with old convId: {}"
,
conversationId
);
}
}
sendTrustRequestConfirm
(
peer_account
,
conversationId
);
sendTrustRequestConfirm
(
peer_account
,
conversationId
);
info_
->
contacts
->
saveTrustRequests
();
}
}
});
});
return
true
;
return
true
;
...
...
This diff is collapsed.
Click to expand it.
src/jamidht/contact_list.cpp
+
1
−
0
View file @
577564e6
...
@@ -254,6 +254,7 @@ ContactList::saveContacts() const
...
@@ -254,6 +254,7 @@ ContactList::saveContacts() const
void
void
ContactList
::
saveTrustRequests
()
const
ContactList
::
saveTrustRequests
()
const
{
{
// mutex_ MUST BE locked
std
::
ofstream
file
(
path_
/
"incomingTrustRequests"
,
std
::
ofstream
file
(
path_
/
"incomingTrustRequests"
,
std
::
ios
::
trunc
|
std
::
ios
::
binary
);
std
::
ios
::
trunc
|
std
::
ios
::
binary
);
msgpack
::
pack
(
file
,
trustRequests_
);
msgpack
::
pack
(
file
,
trustRequests_
);
...
...
This diff is collapsed.
Click to expand it.
src/jamidht/contact_list.h
+
3
−
3
View file @
577564e6
...
@@ -128,9 +128,6 @@ public:
...
@@ -128,9 +128,6 @@ public:
bool
acceptTrustRequest
(
const
dht
::
InfoHash
&
from
);
bool
acceptTrustRequest
(
const
dht
::
InfoHash
&
from
);
bool
discardTrustRequest
(
const
dht
::
InfoHash
&
from
);
bool
discardTrustRequest
(
const
dht
::
InfoHash
&
from
);
/** Should be called only after onTrustRequest */
void
saveTrustRequests
()
const
;
/* Devices */
/* Devices */
const
std
::
map
<
dht
::
PkId
,
KnownDevice
>&
getKnownDevices
()
const
{
return
knownDevices_
;
}
const
std
::
map
<
dht
::
PkId
,
KnownDevice
>&
getKnownDevices
()
const
{
return
knownDevices_
;
}
void
foundAccountDevice
(
const
dht
::
PkId
&
device
,
void
foundAccountDevice
(
const
dht
::
PkId
&
device
,
...
@@ -169,6 +166,9 @@ private:
...
@@ -169,6 +166,9 @@ private:
void
loadKnownDevices
();
void
loadKnownDevices
();
void
saveKnownDevices
()
const
;
void
saveKnownDevices
()
const
;
/** Should be called only after onTrustRequest */
void
saveTrustRequests
()
const
;
};
};
}
// namespace jami
}
// namespace jami
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment