Repository navigation
Commit a6baad8
committed
Dispatch preferencesChanged WebKit calls to the main thread
PBWebHistoryController's preferencesChanged touched WebView's
windowScriptObject synchronously from whatever thread posted
NSUserDefaultsDidChangeNotification. WebKit requires
windowScriptObject to be accessed only on the main thread and
raises WebKitThreadingException otherwise, crashing the process.
- Wrap the script call in dispatch_async(dispatch_get_main_queue())
- Found via the new GitXTests unit-test target: XCTest's bootstrap
registers NSUserDefaults from a background thread during process
startup, crashing GitX consistently
- Unrelated to issue #563 (duplicate commits race)1 parent 21e5ff0 commit a6baad8
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
346 | 346 | | |
347 | 347 | | |
348 | 348 | | |
349 | | - | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
350 | 352 | | |
351 | 353 | | |
352 | 354 | | |
0 commit comments