Commit 318d4734 authored by Joel Martin's avatar Joel Martin

Tolerate fragmented ServerInit.

Issue #39: https://github.com/kanaka/noVNC/issues/issue/39
parent 0f7f146f
...@@ -815,9 +815,7 @@ init_msg = function() { ...@@ -815,9 +815,7 @@ init_msg = function() {
break; break;
case 'SecurityResult' : case 'SecurityResult' :
if (rQlen() < 4) { if (rQwait("VNC auth response ", 24)) { return false; }
return fail("Invalid VNC auth response");
}
switch (rQshift32()) { switch (rQshift32()) {
case 0: // OK case 0: // OK
// Fall through to ClientInitialisation // Fall through to ClientInitialisation
...@@ -848,9 +846,7 @@ init_msg = function() { ...@@ -848,9 +846,7 @@ init_msg = function() {
break; break;
case 'ServerInitialisation' : case 'ServerInitialisation' :
if (rQlen() < 24) { if (rQwait("server initialization", 24)) { return false; }
return fail("Invalid server initialisation");
}
/* Screen size */ /* Screen size */
fb_width = rQshift16(); fb_width = rQshift16();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment