From: Akihiko Odaki <akihiko.od...@daynix.com>

[-QemuCocoaView displayConsole:] can be called anytime so explicitly
take the BQL before it calls console_select().

Signed-off-by: Akihiko Odaki <akihiko.od...@daynix.com>
Tested-by: Rene Engel <reneenge...@emailn.de>
Reviewed-by: Peter Maydell <peter.mayd...@linaro.org>
Message-ID: <20240224-cocoa-v12-9-e89f70bdd...@daynix.com>
Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org>
---
 ui/cocoa.m | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/ui/cocoa.m b/ui/cocoa.m
index 6c9efa0c20..bc63043158 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -1379,7 +1379,9 @@ - (void)toggleZoomInterpolation:(id) sender
 /* Displays the console on the screen */
 - (void)displayConsole:(id)sender
 {
-    console_select([sender tag]);
+    with_bql(^{
+        console_select([sender tag]);
+    });
 }
 
 /* Pause the guest */
-- 
2.41.0


Reply via email to