-
Notifications
You must be signed in to change notification settings - Fork 191
throw no more handles if a timer could not be created #2808
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
This is a draft for now because it needs consideration for other platforms and whether after 25 years there is a reason that this case was allowed to fail silently on Windows. On macOS there is a pointless null check in the same place because an NPE would have already been raised. On GTK I need to investigate more because the functions are not documented as being able to fail. macOS: eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java Lines 5381 to 5390 in bb954ac
GTK: eclipse.platform.swt/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Display.java Lines 5750 to 5759 in 286e614
|
Test Results 172 files + 3 172 suites +3 23m 56s ⏱️ - 3m 42s Results for commit 74c1657. ± Comparison against base commit 35ce202. This pull request removes 1 and adds 57 tests. Note that renamed tests count towards both.This pull request skips 1 test.♻️ This comment has been updated with latest results. |
At the moment the code silently fails on calling timerExec if there are no handles left or it fails for other reasons. Relates to eclipse-platform#2806 where we can see that we are running out of handles, but the timerExec does not report a failure. On Windows timer handles are related to user objects and are relatively limited (10,000). For Linux and macOS the timers seem only to fail in out of memory situations.
My latest commit adds throwing no more handles on macos and gtk if the timer creation routines return 0/null so they also don't silently fail anymore. I plan to submit this soon if there are no objections. |
At the moment the code silently fails on calling timerExec if there are no handles left or it fails for other reasons.
Relates to #2806 where we can see that we are running out of handles, but the timerExec does not report a failure.