Update _abnf.py

bug fix.
Root cause: append int to string.
This commit is contained in:
coolyuyuyu
2015-01-15 20:03:54 +08:00
parent c071595cf3
commit 02d970a4bb

View File

@@ -108,7 +108,7 @@ class ABNF(object):
raise WebSocketProtocolException("rsv is not implemented, yet") raise WebSocketProtocolException("rsv is not implemented, yet")
if self.opcode not in ABNF.OPCODES: if self.opcode not in ABNF.OPCODES:
raise WebSocketProtocolException("Invalid opcode " + self.opcode) raise WebSocketProtocolException("Invalid opcode " + str(self.opcode))
if self.opcode == ABNF.OPCODE_PING and not self.fin: if self.opcode == ABNF.OPCODE_PING and not self.fin:
raise WebSocketProtocolException("Invalid ping frame.") raise WebSocketProtocolException("Invalid ping frame.")