aboutsummaryrefslogtreecommitdiffstats
path: root/lib/wx/c_src
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2019-01-25 08:38:33 +0100
committerDan Gudmundsson <[email protected]>2019-01-25 09:48:48 +0100
commitd7805acb99f2b7ccd97541d189f6494966564d98 (patch)
tree4ef468ddf69cac6d3a2497fb369e078e43837c51 /lib/wx/c_src
parentf180ccc75a7d2cef6b469d2e4a737cffbef7c951 (diff)
downloadotp-d7805acb99f2b7ccd97541d189f6494966564d98.tar.gz
otp-d7805acb99f2b7ccd97541d189f6494966564d98.tar.bz2
otp-d7805acb99f2b7ccd97541d189f6494966564d98.zip
Fix showModal crash on Mojave
Invoking wxDialog:showModal could cause a seg-fault on Mojave if invoked from inside event callback. Which could happen when wx dispatch commands inside send_event. Wx dispatches commands inside send_event because some events will not return to idle mode (on Windows) until mouse is released. These events are (at least) wxSize and wxMove according to previous commits. Solved by only dispatching commands for those events. Another solution might be to ifdef the code to only do it on windows or not do it on the Mac.
Diffstat (limited to 'lib/wx/c_src')
-rw-r--r--lib/wx/c_src/gen/wxe_events.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/wx/c_src/gen/wxe_events.cpp b/lib/wx/c_src/gen/wxe_events.cpp
index 45da18f7c7..8c3283a670 100644
--- a/lib/wx/c_src/gen/wxe_events.cpp
+++ b/lib/wx/c_src/gen/wxe_events.cpp
@@ -1,7 +1,7 @@
/*
* %CopyrightBegin%
*
- * Copyright Ericsson AB 2008-2018. All Rights Reserved.
+ * Copyright Ericsson AB 2008-2019. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -910,7 +910,7 @@ case 238: {// wxDropFilesEvent
} else {
send_res = rt.send();
if(cb->skip) event->Skip();
- if(app->recurse_level < 1 && Etype->cID != 168) {
+ if(app->recurse_level < 1 && (Etype->cID == 171 || Etype->cID == 172)) {
app->recurse_level++;
app->dispatch_cmds();
app->recurse_level--;