Skip to content
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

Abstract socket name length fix #2375

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

Miniwoffer
Copy link
Contributor

When using

bind_to_unix 
connect_to_unix

with either @ or \\0 prefix the length in not calculated correctly and an additional null byte is included in the name at the end. Included in this pull-request is a fix and a set of tests, two of which the old implementation fails with:

check_core.c:66:F:socket_tests:test_uwsgi_connect_to_unix:0: Failed to connect with abstract socket with '@' prefix
check_core.c:84:F:socket_tests:test_uwsgi_bind_to_unix_normal:0: Failed to connect to abstract socket

 - Fixed a bug for abstract socket where with '@' and "\\0" prefix, the
   socket name would contain a null byte at the end.
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

Successfully merging this pull request may close these issues.

1 participant