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

Websockets do not disconnect signals correctly on abort

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3: Somewhat important
    • Resolution: Done
    • Affects Version/s: 5.9.1
    • Fix Version/s: 5.9.8
    • Component/s: WebSockets
    • Labels:
      None
    • Commits:
      dad63663fcc6590353ec426337b0126b967da173

      Description

      I have a situation where I'm calling abort on a websocket and then attempting to open a connection again. Sometimes it gets stuck and doesn't reconnect properly, my investigation shows that the signals from the previous QTcpSocket were not disconnected from QWebSocketPrivate::processStateChanged leading to confusion.

      I don't have example code to reproduce this handy because it requires a custom server and client and is slightly timing dependent. However https://codereview.qt-project.org/#/c/203110/ and http://doc.qt.io/qt-5/qobject.html#disconnect-3 combined make the issue fairly evident.

        Attachments

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

          Activity

            People

            Assignee:
            aalpert Alan Alpert
            Reporter:
            aalpert Alan Alpert
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes