mirror of
https://github.com/sshuttle/sshuttle.git
synced 2024-11-25 01:13:37 +01:00
reduce
This commit is contained in:
parent
d0f0aa9f17
commit
9bcca27965
@ -5,8 +5,6 @@ import errno
|
|||||||
logprefix = ''
|
logprefix = ''
|
||||||
verbose = 0
|
verbose = 0
|
||||||
|
|
||||||
binary_type = bytes
|
|
||||||
|
|
||||||
|
|
||||||
def b(s):
|
def b(s):
|
||||||
return s.encode("ASCII")
|
return s.encode("ASCII")
|
||||||
|
@ -5,7 +5,7 @@ import errno
|
|||||||
import select
|
import select
|
||||||
import os
|
import os
|
||||||
|
|
||||||
from sshuttle.helpers import b, binary_type, log, debug1, debug2, debug3, Fatal
|
from sshuttle.helpers import b, log, debug1, debug2, debug3, Fatal
|
||||||
|
|
||||||
MAX_CHANNEL = 65535
|
MAX_CHANNEL = 65535
|
||||||
LATENCY_BUFFER_SIZE = 32768
|
LATENCY_BUFFER_SIZE = 32768
|
||||||
@ -382,7 +382,7 @@ class Mux(Handler):
|
|||||||
# log('outbuf: %d %r\n' % (self.amount_queued(), ob))
|
# log('outbuf: %d %r\n' % (self.amount_queued(), ob))
|
||||||
|
|
||||||
def send(self, channel, cmd, data):
|
def send(self, channel, cmd, data):
|
||||||
assert isinstance(data, binary_type)
|
assert isinstance(data, bytes)
|
||||||
assert len(data) <= 65535
|
assert len(data) <= 65535
|
||||||
p = struct.pack('!ccHHH', b('S'), b('S'), channel, cmd, len(data)) \
|
p = struct.pack('!ccHHH', b('S'), b('S'), channel, cmd, len(data)) \
|
||||||
+ data
|
+ data
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
import sys
|
|
||||||
|
|
||||||
good_python = sys.version_info >= (3, 5)
|
|
||||||
|
|
||||||
collect_ignore = []
|
|
||||||
if not good_python:
|
|
||||||
collect_ignore.append("client")
|
|
Loading…
Reference in New Issue
Block a user