]> git.proxmox.com Git - mirror_novnc.git/commitdiff
utils/websocket.py: add HyBi 13 support.
authorJoel Martin <github@martintribe.org>
Wed, 31 Aug 2011 23:06:58 +0000 (18:06 -0500)
committerJoel Martin <github@martintribe.org>
Wed, 31 Aug 2011 23:06:58 +0000 (18:06 -0500)
Pull from websockify 6e26306.

utils/websocket.py

index a39be5e26177fb5a1db8212f283c84b5d33bc8f5..e906b7e0543ce878e8589af097789bcf91476449 100644 (file)
@@ -615,9 +615,10 @@ Sec-WebSocket-Accept: %s\r
                 raise self.EClose("Python >= 2.6 and numpy module is required for HyBi-07 or greater")
 
             # HyBi-07 report version 7
-            # HyBi-08 - HyBi-10 report version 8
-            if ver in ['7', '8']:
-                self.version = "hybi-0" + ver
+            # HyBi-08 - HyBi-12 report version 8
+            # HyBi-13 reports version 13
+            if ver in ['7', '8', '13']:
+                self.version = "hybi-%02d" % int(ver)
             else:
                 raise self.EClose('Unsupported protocol version %s' % ver)