-
Notifications
You must be signed in to change notification settings - Fork 29.6k
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
doc: server.listen truncates socket path on unix #6659
Closed
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
filesystem, and will *persist until unlinked*. | ||
filesystem path name. It gets truncated to `sizeof(sockaddr_un.sun_path)` | ||
bytes, decreased by 1. It varies on different operating system between 91 and | ||
107 bytes. The typical values are 107 on Linux and 103 on OSX. The path is |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The convention in the documentation seems to be to spell it as 'OS X' (space before the X.)
EDIT: In the commit log as well.
LGTM with nit. /cc @nodejs/documentation |
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`.
jeanregisser
force-pushed
the
doc-unix-sock-path-listen
branch
from
May 10, 2016 08:43
8e72712
to
f0423d0
Compare
LGTM |
2 similar comments
LGTM |
LGTM |
addaleax
pushed a commit
that referenced
this pull request
May 12, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Landed in 4c24fbf, removed trailing whitespace upon landing. Thanks! |
evanlucas
pushed a commit
that referenced
this pull request
May 17, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
@addaleax lts? |
@thealphanerd yep 👍 |
MylesBorins
pushed a commit
that referenced
this pull request
Jul 11, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins
pushed a commit
that referenced
this pull request
Jul 11, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins
pushed a commit
that referenced
this pull request
Jul 12, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins
pushed a commit
that referenced
this pull request
Jul 12, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Merged
MylesBorins
pushed a commit
that referenced
this pull request
Jul 14, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
MylesBorins
pushed a commit
that referenced
this pull request
Jul 14, 2016
Internally it ends up calling `uv_pipe_bind` with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bind This is NOT a bug, but a restriction of the unix socket api, as it stores the path in `sockaddr_un.sun_path` (104 chars on OS X, 108 chars on Linux), see `man unix`. PR-URL: #6659 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Alexander Makarenko <estliberitas@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Checklist
Affected core subsystem(s)
doc
Description of change
I found out that calling the following code would create a UNIX socket with a truncated path:
Internally it ends up calling
uv_pipe_bind
with the given path which itself is documented to truncate the path. See http://docs.libuv.org/en/v1.x/pipe.html#c.uv_pipe_bindThis is NOT a bug, but a restriction of the unix socket api, as it stores the path in
sockaddr_un.sun_path
(104 chars on OSX, 108 chars on Linux), seeman unix
.