Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-41209

QWebsocket disconnects after sending large binary message

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P2: Important P2: Important
    • 5.15, 6.2
    • 5.3.0, 5.5.0 Beta
    • WebSockets
    • None
    • Windows 7 64bit MingW48 / VS2013, OS X 10.10.3
    • macOS

      When a QWebSocket sends a large binary message (I used 1352101 bytes), the underlying message is understood to be broken into frames.

      webSocket->sendBinaryMessage(data); // returns 1352101 bytes as expected.

      To confirm on the server side, the receiving QWebSocketServer receives the following binary frames from the incoming socket:
      524288 (isLastFrame = false)
      524288 (isLastFrame = false)

      • the last frame is never received and the QWebSocket closes internally with close code 1000 (Normal). The binaryMessageReceived signal is never emitted from the socket.

      The specification of websockets has a much higher upper limit than a couple of Mb so I don't understand why the message hasn't been received in its entirety.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            oyheskes Øystein Heskestad
            miketrahearn Mike Trahearn
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes