diff --git a/src/motif/app.cpp b/src/motif/app.cpp index a723826ec3..d17e8fc734 100644 --- a/src/motif/app.cpp +++ b/src/motif/app.cpp @@ -304,7 +304,7 @@ void wxApp::SetTopLevelWidget(WXDisplay* display, WXWidget widget) bool wxApp::Yield(bool onlyIfNeeded) { - bool s_inYield = FALSE; + static bool s_inYield = FALSE; if ( s_inYield ) { diff --git a/src/x11/app.cpp b/src/x11/app.cpp index 306e7b4081..1c924a1822 100644 --- a/src/x11/app.cpp +++ b/src/x11/app.cpp @@ -786,7 +786,7 @@ bool wxApp::Yield(bool onlyIfNeeded) int i; for (i = 0; i < 2; i++) { - bool s_inYield = FALSE; + static bool s_inYield = FALSE; if ( s_inYield ) {