Current implementation of noexec blocks thread until tor_run_main returns. Instead, a handle should be returned that terminates the thread, unloads libtor, and returns the result.
This is needed so that, in the event a control connection cannot be established, or a startup sequence failure occurs, tor can be stopped (much like killing it as if it were running as a child process).
Current implementation of
noexec
blocks thread untiltor_run_main
returns. Instead, a handle should be returned that terminates the thread, unloadslibtor
, and returns the result.This is needed so that, in the event a control connection cannot be established, or a startup sequence failure occurs, tor can be stopped (much like killing it as if it were running as a child process).