Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Example code "sslechoclient.html" not connecting to sslechoserver
Forum Updated to NodeBB v4.3 + New Features

Example code "sslechoclient.html" not connecting to sslechoserver

Scheduled Pinned Locked Moved General and Desktop
2 Posts 1 Posters 960 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • _ Offline
    _ Offline
    __Alex__
    wrote on last edited by
    #1

    Hello,

    I am trying to run the example project sslechoserver in Qt 5.4 on Ubuntu 14.04 32 Bit. The server runs just fine and the sslechoclient example project can connect to the server, too, but when I try to run sslechoclient.html (which can be found in the folder of the sslechoserver example project) and I click the connect button I get "ERROR: undefined", followed by "DISCONNECTED".

    I found out that the html file's error is being thrown inside the "websocket.onerror" function and not in the catch-block inside the "initWebSocket" function.

    If I click the state button after this error happened, I get "WebSocket state = 3 ( CLOSED )".

    Unfortunately I have no idea what went wrong exactly. Does anyone know how to solve this?

    Cheers
    Alex

    1 Reply Last reply
    1
    • _ Offline
      _ Offline
      __Alex__
      wrote on last edited by
      #2

      Additional info:
      I installed the example client and server from http://www.tutorialspoint.com/html5/html5_websocket.htm
      The server was accessible from all 3 of my clients (the Html/Js-Clients from both examples as well as the Qt client from C++). The Qt server however was only accessible from the Qt C++ client.

      Since the Python server uses unencrypted connections, I tested this, too, but the Python server gave me a reaction to encrypted connections, too (i.e. an error), while the Qt server didn't react at all no matter what kind of connection was tried to make.

      Also I retrieved the onClosed-code in case of the error in the Qt server. It is 1006, which means that apparently the server was not found at all.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved