Skip to content

Commit 19b7c1d

Browse files
author
kai
committed
Update comment
1 parent 2e01885 commit 19b7c1d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

IdentityCore/src/util/mac/MSIDXpcSingleSignOnProvider.m

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,8 @@ - (void)getXpcService:(id<MSIDXpcProviderCaching>)xpcProviderCache withContinueB
394394
return;
395395
}
396396

397-
// When a connection is not available, or the Xpc decides to reject the connection, both the interrupt handler and invalidation handler will be called, which will cause unexpected dispatch_group_leave in the completion block. Adding a manual check to prevent this from happening.
397+
// Ensure that both the interruption handler and invalidation handler do not trigger unexpected dispatch_group_leave
398+
// when the connection is unavailable or rejected by the XPC. This is achieved by adding a manual check.
398399
__block BOOL isConnectionErroredOut = NO;
399400
[connection resume];
400401
[connection setInterruptionHandler:^{
@@ -413,6 +414,7 @@ - (void)getXpcService:(id<MSIDXpcProviderCaching>)xpcProviderCache withContinueB
413414
isConnectionErroredOut = YES;
414415
continueBlock(nil, nil, xpcError);
415416
}
417+
416418
if (continueBlock) continueBlock(nil, nil, xpcError);
417419
}];
418420

0 commit comments

Comments
 (0)