Skip to content

Don’t call exit when opening the socket fails #3

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

Open
zopsicle opened this issue Apr 3, 2020 · 2 comments
Open

Don’t call exit when opening the socket fails #3

zopsicle opened this issue Apr 3, 2020 · 2 comments

Comments

@zopsicle
Copy link

zopsicle commented Apr 3, 2020

Apparently libfcgi calls perror and exit when it cannot open the listening socket, which is rather brutal. Not sure if fixing that would be in the scope of this project, in contrast with fixing it upstream.

FastCGI::NativeCall.new(path => '/tmp/foo/bar.sock');
# expected behavior: throw exception or return failure
# actual behavior: call to exit()
@jonathanstowe
Copy link
Owner

Yeah, that is a bit crap really. As this is basically using a fork of the libfcgi I think it would be easiest just to fix it here. I'll take a look in the next week or so.

Thanks for the report.

@jonathanstowe
Copy link
Owner

It seems that the os_unix.c has exit all over the place, I'll have to think about how to signal the failure to the module and handle it appropriately a bit harder.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants