Remove reinit_crypto calls

This commit is contained in:
Daniel A. Wozniak 2024-05-25 15:51:32 -07:00 committed by Daniel Wozniak
parent 7d35efe5b9
commit 7eb4fb6cd3
2 changed files with 0 additions and 6 deletions

View file

@ -73,7 +73,6 @@ def daemonize(redirect_out=True):
pid = os.fork()
if pid > 0:
# exit first parent
salt.utils.crypt.reinit_crypto()
os._exit(salt.defaults.exitcodes.EX_OK)
except OSError as exc:
log.error("fork #1 failed: %s (%s)", exc.errno, exc)
@ -89,14 +88,11 @@ def daemonize(redirect_out=True):
try:
pid = os.fork()
if pid > 0:
salt.utils.crypt.reinit_crypto()
sys.exit(salt.defaults.exitcodes.EX_OK)
except OSError as exc:
log.error("fork #2 failed: %s (%s)", exc.errno, exc)
sys.exit(salt.defaults.exitcodes.EX_GENERIC)
salt.utils.crypt.reinit_crypto()
# A normal daemonization redirects the process output to /dev/null.
# Unfortunately when a python multiprocess is called the output is
# not cleanly redirected and the parent process dies when the

View file

@ -461,8 +461,6 @@ class Terminal:
else:
os.close(tty_fd)
salt.utils.crypt.reinit_crypto()
if preexec_fn is not None:
preexec_fn()