use byte literals in multiprocessing
This commit is contained in:
parent
41a7ce0a2e
commit
b09c9396cd
|
@ -352,14 +352,9 @@ if sys.platform == 'win32':
|
||||||
|
|
||||||
MESSAGE_LENGTH = 20
|
MESSAGE_LENGTH = 20
|
||||||
|
|
||||||
CHALLENGE = '#CHALLENGE#'
|
CHALLENGE = b'#CHALLENGE#'
|
||||||
WELCOME = '#WELCOME#'
|
WELCOME = b'#WELCOME#'
|
||||||
FAILURE = '#FAILURE#'
|
FAILURE = b'#FAILURE#'
|
||||||
|
|
||||||
if sys.version_info >= (3, 0): # XXX can use bytes literals in 2.6/3.0
|
|
||||||
CHALLENGE = CHALLENGE.encode('ascii')
|
|
||||||
WELCOME = WELCOME.encode('ascii')
|
|
||||||
FAILURE = FAILURE.encode('ascii')
|
|
||||||
|
|
||||||
def deliver_challenge(connection, authkey):
|
def deliver_challenge(connection, authkey):
|
||||||
import hmac
|
import hmac
|
||||||
|
|
Loading…
Reference in New Issue