summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--macosx/main.mm7
1 files changed, 3 insertions, 4 deletions
diff --git a/macosx/main.mm b/macosx/main.mm
index 300000273..30ae392ae 100644
--- a/macosx/main.mm
+++ b/macosx/main.mm
@@ -9,16 +9,15 @@
static void hb_error_handler(const char *errmsg)
{
- @autoreleasepool
- {
+ dispatch_async(dispatch_get_main_queue(), ^{
NSAlert *alert = [[NSAlert alloc] init];
[alert setMessageText:NSLocalizedString(@"Internal Error.", @"")];
[alert setInformativeText:@(errmsg)];
[alert runModal];
[alert release];
+ });
- fprintf(stderr, "GUI ERROR dialog: %s\n", errmsg );
- }
+ fprintf(stderr, "GUI ERROR dialog: %s\n", errmsg );
}
int main(int argc, const char **argv)