Browse Source

if(preg_match("/Sec-WebSocket-Key: *(.*?)\r\n/i", $buffer, $match))

npc 10 years ago
parent
commit
cca0a6463c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Protocols/Websocket.php

+ 1 - 1
Protocols/Websocket.php

@@ -293,7 +293,7 @@ class Websocket implements \Workerman\Protocols\ProtocolInterface
             
             
             // 解析Sec-WebSocket-Key
             // 解析Sec-WebSocket-Key
             $Sec_WebSocket_Key = '';
             $Sec_WebSocket_Key = '';
-            if(preg_match("/Sec-WebSocket-Key: *(.*?)\r\n/", $buffer, $match))
+            if(preg_match("/Sec-WebSocket-Key: *(.*?)\r\n/i", $buffer, $match))
             {
             {
                 $Sec_WebSocket_Key = $match[1];
                 $Sec_WebSocket_Key = $match[1];
             }
             }