Skip to content

Commit f8eb6a1

Browse files
gtk: Fix macos main thread check
Fixes #1235
1 parent 4a68dcb commit f8eb6a1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gtk4/src/rt.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -99,9 +99,9 @@ pub unsafe fn set_initialized() {
9999
// OS X has its own notion of the main thread and init must be called on that thread.
100100
#[cfg(target_os = "macos")]
101101
{
102-
assert_eq!(
102+
assert_ne!(
103103
pthread_main_np(),
104-
1,
104+
0,
105105
"Attempted to initialize GTK on OSX from non-main thread"
106106
);
107107
}

0 commit comments

Comments
 (0)