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
fee58681
Commit
fee58681
authored
Oct 27, 2016
by
Jason Woods
Committed by
Brian May
Oct 27, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix warning: closed channel got=STOP_SENDING
parent
fbbcc05d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
4 deletions
+14
-4
ssnet.py
sshuttle/ssnet.py
+14
-4
No files found.
sshuttle/ssnet.py
View file @
fee58681
...
...
@@ -503,17 +503,25 @@ class MuxWrapper(SockWrapper):
return
'SW
%
r:Mux#
%
d'
%
(
self
.
peername
,
self
.
channel
)
def
noread
(
self
):
if
not
self
.
shut_read
:
self
.
mux
.
send
(
self
.
channel
,
CMD_TCP_STOP_SENDING
,
b
(
''
))
self
.
setnoread
()
def
setnoread
(
self
):
if
not
self
.
shut_read
:
debug2
(
'
%
r: done reading
\n
'
%
self
)
self
.
shut_read
=
True
self
.
mux
.
send
(
self
.
channel
,
CMD_TCP_STOP_SENDING
,
b
(
''
))
self
.
maybe_close
()
def
nowrite
(
self
):
if
not
self
.
shut_write
:
self
.
mux
.
send
(
self
.
channel
,
CMD_TCP_EOF
,
b
(
''
))
self
.
setnowrite
()
def
setnowrite
(
self
):
if
not
self
.
shut_write
:
debug2
(
'
%
r: done writing
\n
'
%
self
)
self
.
shut_write
=
True
self
.
mux
.
send
(
self
.
channel
,
CMD_TCP_EOF
,
b
(
''
))
self
.
maybe_close
()
def
maybe_close
(
self
):
...
...
@@ -542,9 +550,11 @@ class MuxWrapper(SockWrapper):
def
got_packet
(
self
,
cmd
,
data
):
if
cmd
==
CMD_TCP_EOF
:
self
.
noread
()
# Remote side already knows the status - set flag but don't notify
self
.
setnoread
()
elif
cmd
==
CMD_TCP_STOP_SENDING
:
self
.
nowrite
()
# Remote side already knows the status - set flag but don't notify
self
.
setnowrite
()
elif
cmd
==
CMD_TCP_DATA
:
self
.
buf
.
append
(
data
)
else
:
...
...
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