Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
sshuttle
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pub
sshuttle
Commits
c013386e
Commit
c013386e
authored
Sep 15, 2014
by
Brian May
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
If IPv4 bind but IPv6 succeeds don't error.
parent
a33f6199
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
1 deletion
+9
-1
client.py
src/client.py
+9
-1
No files found.
src/client.py
View file @
c013386e
...
@@ -209,7 +209,15 @@ class MultiListener:
...
@@ -209,7 +209,15 @@ class MultiListener:
if
self
.
v6
:
if
self
.
v6
:
self
.
v6
.
listen
(
backlog
)
self
.
v6
.
listen
(
backlog
)
if
self
.
v4
:
if
self
.
v4
:
try
:
self
.
v4
.
listen
(
backlog
)
self
.
v4
.
listen
(
backlog
)
except
socket
.
error
,
e
:
# on some systems v4 bind will fail if the v6 suceeded,
# in this case the v6 socket will receive v4 too.
if
e
.
errno
==
errno
.
EADDRINUSE
and
self
.
v6
:
self
.
v4
=
None
else
:
raise
e
def
bind
(
self
,
address_v6
,
address_v4
):
def
bind
(
self
,
address_v6
,
address_v4
):
if
address_v6
and
self
.
v6
:
if
address_v6
and
self
.
v6
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment