Re: how do I create websocket client with libcurl (was: A quick hack to support Websocket with libcurl)
Date: Tue, 17 Mar 2015 10:50:13 +0900
dummy code was wrong.
I attached correct dummy code.
2015-03-17 9:54 GMT+09:00 YAMADA Yasuharu <
> Hi Danial,
> 2015-03-16 19:56 GMT+09:00 Daniel Stenberg <daniel_at_haxx.se>:
>> I hope it works fine for 7.40.0 or later.
>> Why don't you try and then tell us?
> sorry I did not focus this problem long time.
> I try to test 7.28.0~7.40.0 these days.
> So I have questions:
>>> - that dummy code is correct how to use cURL API?
>> It lacks a lot of checks and it uses a busy-loop so I wouldn't call it
>> correct, but I believe it should work.
> I'd like to confirm.
> Is it correct how to use cURL API like that dummy code?
> Set a few break-point and figure out what happens?
> curl_multi_perform() CONNECT to server
> -> easy_connection()
> -> Curl_getconnectinfo()
> -> data->multi_easy is NULL because it does not use easy_perform()
> -> return CURL_SOCKET_BAD by Curl_getconnectinfo()
> # I guess
> is convenient for this issue.
> - there is another way to create the application?
>> Skip libcurl and just connect a socket to the server? You're not using
>> libcurl very much anyway...
> The application is web browser and we use libcurl for it more than 4 years.
> I know it can connect to websocket server through socket.
> but for browsing, the connection through proxy, authentication, SSL/TLS,
> It is difficult to use socket directory.
> Best regards,
> YAMADA Yasuharu
> ACCESS CO., LTD.
- text/x-csrc attachment: websocket_dummy.c