Skip to content

Commit 4a81ea7

Browse files
jtung-appleratgr
authored andcommitted
[Darwin] MTRDevice _reattemptSubscriptionNowIfNeededWithReason needs to be called while holding lock (project-chip#37710)
1 parent 2bb8928 commit 4a81ea7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/darwin/Framework/CHIP/MTRDevice_Concrete.mm

+1
Original file line numberDiff line numberDiff line change
@@ -1072,6 +1072,7 @@ - (void)_triggerResubscribeWithReason:(NSString *)reason nodeLikelyReachable:(BO
10721072
// The subscription reattempt here eventually asyncs onto the matter queue for session,
10731073
// and should be called after the above ReleaseSession call, to avoid churn.
10741074
if (shouldReattemptSubscription) {
1075+
std::lock_guard lock(_lock);
10751076
[self _reattemptSubscriptionNowIfNeededWithReason:reason];
10761077
}
10771078
}

0 commit comments

Comments
 (0)