Copyright © https://mongoose-os.com

Mongoose OS Forum

frame

Websocket connection "cannot parse address" problem

dkayahandkayahan Turkey
edited November 2017 in Mongoose Networking Library

Hello,

I'am trying to connect a websocket with Mongoose 6.9 but getting "cannot parse address" error.

Here is my code:

const char url = "wss://ws.xxx?id=xxx&key=yyy"

const char* errPtr;
opts.error_string = &errPtr;
nc = mg_connect_ws_opt(&mgr, &eventHandler, opts, url, NULL, NULL);

error_string returns "cannot parse address"

This code works if I try to connect same address without parameters, but server uses parameters for authentication.

I tried to connect same url by javascript Websockets and it worked.

Thanks

Comments

Sign In or Register to comment.