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

[macOS] WebProcess names in Activity Monitor cannot include non-Latin1 characters #14226

Merged

Conversation

cdumez
Copy link
Contributor

@cdumez cdumez commented May 23, 2023

c452365

[macOS] WebProcess names in Activity Monitor cannot include non-Latin1 characters
https://bugs.webkit.org/show_bug.cgi?id=257179
rdar://109691473

Reviewed by Alex Christensen.

We are sending the application name as UTF-8 over XPC like so:
```
xpc_dictionary_set_string(bootstrapMessage.get(), "ui-process-name", [[[NSProcessInfo processInfo] processName] UTF8String]);
```

But we were decoding it as Latin1 instead of UTF-8 on the recipient side. This
was the cause of the bug.

* Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.mm:
(WebKit::XPCServiceInitializerDelegate::getClientProcessName):

Canonical link: https://commits.webkit.org/264403@main

d7071ab

Misc iOS, tvOS & watchOS macOS Linux Windows
βœ… πŸ§ͺ style βœ… πŸ›  ios βœ… πŸ›  mac βœ… πŸ›  wpe   πŸ›  wincairo
βœ… πŸ›  ios-sim βœ… πŸ›  mac-AS-debug   πŸ§ͺ wpe-wk2
βœ… πŸ§ͺ webkitperl βœ… πŸ§ͺ ios-wk2   πŸ§ͺ api-mac βœ… πŸ›  gtk
βœ… πŸ§ͺ ios-wk2-wpt   πŸ§ͺ gtk-wk2
  πŸ§ͺ api-ios βœ… πŸ§ͺ mac-wk2 βœ… πŸ§ͺ api-gtk
βœ… πŸ›  tv   πŸ§ͺ mac-AS-debug-wk2
βœ… πŸ›  tv-sim
βœ… πŸ›  πŸ§ͺ merge βœ… πŸ›  watch
βœ… πŸ›  watch-sim

@cdumez cdumez self-assigned this May 23, 2023
@cdumez cdumez added the WebKit2 Bugs relating to the WebKit2 API layer label May 23, 2023
@cdumez cdumez added the merge-queue Applied to send a pull request to merge-queue label May 23, 2023
…1 characters

https://bugs.webkit.org/show_bug.cgi?id=257179
rdar://109691473

Reviewed by Alex Christensen.

We are sending the application name as UTF-8 over XPC like so:
```
xpc_dictionary_set_string(bootstrapMessage.get(), "ui-process-name", [[[NSProcessInfo processInfo] processName] UTF8String]);
```

But we were decoding it as Latin1 instead of UTF-8 on the recipient side. This
was the cause of the bug.

* Source/WebKit/Shared/EntryPointUtilities/Cocoa/XPCService/XPCServiceEntryPoint.mm:
(WebKit::XPCServiceInitializerDelegate::getClientProcessName):

Canonical link: https://commits.webkit.org/264403@main
@webkit-commit-queue
Copy link
Collaborator

Committed 264403@main (c452365): https://commits.webkit.org/264403@main

Reviewed commits have been landed. Closing PR #14226 and removing active labels.

@webkit-commit-queue webkit-commit-queue merged commit c452365 into WebKit:main May 23, 2023
@webkit-commit-queue webkit-commit-queue removed the merge-queue Applied to send a pull request to merge-queue label May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WebKit2 Bugs relating to the WebKit2 API layer
Projects
None yet
4 participants