Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Closing fd created by gnutls_global_init when ran with `--daemon` #271
If I start nzbget 17.1 with
And when I connected to the web user interface it crashes
So I did some tracing - I added a sleep in
After everything is started up it becomes:
I then used ltrace to see what is opening it
So it seems the strategy for closing all fds causes some problems with gnutls which uses an fd for
I did not have this issue with 16.4
Currently as a workaround I just start it with
added a commit
Sep 9, 2016
I removed the code which closed all file descriptors. The whole daemonize-function was copied from somewhere many years ago without full understanding of what it does and why.
I believe it wasn't correct to close all file descriptors, don't see a reason for that. Only descriptors for standard IO must be reinitialized.
Please test with GnuTLS on your system.