(ws) ws_cobra_publish: register callbacks before connecting
This commit is contained in:
parent
e4aed56d72
commit
db0ff4ecd1
@ -43,7 +43,6 @@ namespace ix
|
||||
rolesecret,
|
||||
ix::WebSocketPerMessageDeflateOptions(true),
|
||||
tlsOptions);
|
||||
conn.connect();
|
||||
|
||||
// Display incoming messages
|
||||
std::atomic<bool> authenticated(false);
|
||||
@ -94,6 +93,8 @@ namespace ix
|
||||
}
|
||||
});
|
||||
|
||||
conn.connect();
|
||||
|
||||
while (!authenticated)
|
||||
;
|
||||
while (!messageAcked)
|
||||
|
Loading…
x
Reference in New Issue
Block a user