-
Notifications
You must be signed in to change notification settings - Fork 446
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
client: don't hang if detection processes hang #5190
Commits on Apr 9, 2023
-
Code cleanup in preparation for fixing GPU detect issue
lib/util.cpp had become a landfill of unrelated stuff - move the process-related code to lib/proc_control.cpp - move file-related code to lib/filesys.cpp - move client mutex code to client/main.cpp The client has 2 unrelated types of mutual exclusion: thread level (between the main and throttle threads) and process level (prevent 2 clients from running on a host). - Rename "client_mutex" to "client_thread_mutex". - parse.h: don't declare boinc_is_finite(); include the .h file
Configuration menu - View commit details
-
Copy full SHA for ce28e67 - Browse repository at this point
Copy the full SHA ce28e67View commit details -
Configuration menu - View commit details
-
Copy full SHA for 615c642 - Browse repository at this point
Copy the full SHA 615c642View commit details -
Configuration menu - View commit details
-
Copy full SHA for 391f593 - Browse repository at this point
Copy the full SHA 391f593View commit details -
client: don't hang if detection processes hang
The client runs two "detection processes": - GPU detection - (Mac) check if in CPU emulation mode The client was waiting indefinitely for these to exit. If for some reason they don't exit, the client hangs. Fix: wait no more than 10 sec for them to exit. If still running, kill them and move on. I took the opportunity to clean up the process-related code: - add a time arg to get_exit_status(). If zero, wait indefinitely for the child to exit. Else wait no more than that amount. - get_exit_status() return an error code; the exit status is returned via a parameter. - run_program() no longer takes a time argument. If you want to check for early exit, use get_exit_status() - define PROCESS_ID as HANDLE (Win) or int (other) so we can unify the process interface - remove process_exists(). It wasn't used anywhere, and get_exit_status(... 0) does the same thing. - rename kill_program() to kill_process() - don't use "prog" when you mean "pid"
Configuration menu - View commit details
-
Copy full SHA for 8444da6 - Browse repository at this point
Copy the full SHA 8444da6View commit details
Commits on Apr 10, 2023
-
Configuration menu - View commit details
-
Copy full SHA for c4912d6 - Browse repository at this point
Copy the full SHA c4912d6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4a8b819 - Browse repository at this point
Copy the full SHA 4a8b819View commit details -
get_exit_status(): dt<= means wait indefinitely; dt=0 means non-blocking
Configuration menu - View commit details
-
Copy full SHA for 450914e - Browse repository at this point
Copy the full SHA 450914eView commit details -
Configuration menu - View commit details
-
Copy full SHA for cd1ca87 - Browse repository at this point
Copy the full SHA cd1ca87View commit details -
Note: the unit tests don't really test anything
Configuration menu - View commit details
-
Copy full SHA for 719e7ed - Browse repository at this point
Copy the full SHA 719e7edView commit details -
Change some things back to the way they were;
this PR is getting to big.
Configuration menu - View commit details
-
Copy full SHA for df26141 - Browse repository at this point
Copy the full SHA df26141View commit details -
Getting boinccas to build required some stuff I don't understand
Configuration menu - View commit details
-
Copy full SHA for 6d0e907 - Browse repository at this point
Copy the full SHA 6d0e907View commit details -
Configuration menu - View commit details
-
Copy full SHA for b70a88b - Browse repository at this point
Copy the full SHA b70a88bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 9297527 - Browse repository at this point
Copy the full SHA 9297527View commit details -
Configuration menu - View commit details
-
Copy full SHA for c3481b2 - Browse repository at this point
Copy the full SHA c3481b2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 75e2fd6 - Browse repository at this point
Copy the full SHA 75e2fd6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 89af446 - Browse repository at this point
Copy the full SHA 89af446View commit details -
Configuration menu - View commit details
-
Copy full SHA for 22006b5 - Browse repository at this point
Copy the full SHA 22006b5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 9ed61fc - Browse repository at this point
Copy the full SHA 9ed61fcView commit details
Commits on Apr 11, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 1f19ff3 - Browse repository at this point
Copy the full SHA 1f19ff3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 5326bf5 - Browse repository at this point
Copy the full SHA 5326bf5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7f86425 - Browse repository at this point
Copy the full SHA 7f86425View commit details -
Move run_program() etc. from proc_control.cpp back to util.cpp.
This required changing a bunch of project files, and was turning into a rabbit hole.
Configuration menu - View commit details
-
Copy full SHA for e08b75d - Browse repository at this point
Copy the full SHA e08b75dView commit details -
Win: comment out (currently) unneeded fix
The VS header files have a conflict: various structures (such as STRING) are defined differently in ntsecapi.h than in winternl.h This error appears off and on, for reasons I don't understand. Changes in lib/str_util.h seem to trigger it. Earlier in this PR is was happening. I found a workaround on stackoverflow.com and added it. But now the error is not happening, even without the workaround. So, for now, I'm commenting out the workaround. It's there if we need it in the future.
Configuration menu - View commit details
-
Copy full SHA for b808e06 - Browse repository at this point
Copy the full SHA b808e06View commit details -
Configuration menu - View commit details
-
Copy full SHA for 7af6498 - Browse repository at this point
Copy the full SHA 7af6498View commit details