Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(macos): check WKURLSchemeTask is valid before using #1282

Merged
merged 1 commit into from
Jun 4, 2024

Conversation

pewsheen
Copy link
Contributor

@pewsheen pewsheen commented Jun 4, 2024

Ref: tauri-apps/tauri#9933 #1142 #1189

task in async mode may become invalid at any moment when webview decides to stop the task.
It could happen in any section of the responder, so we need to record which task is valid and check before we use it in the response callback.

One of my concerns is there might be a small chance that the task becomes invalid after we check it and before using it.

@pewsheen pewsheen requested a review from a team as a code owner June 4, 2024 07:12
@wusyong wusyong merged commit f7936b8 into dev Jun 4, 2024
12 checks passed
@wusyong wusyong deleted the fix/macos-mitigate-async-crash branch June 4, 2024 08:16
wusyong added a commit that referenced this pull request Jun 4, 2024
wusyong added a commit that referenced this pull request Jun 4, 2024
@pewsheen pewsheen restored the fix/macos-mitigate-async-crash branch June 4, 2024 08:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants