How to send HTTP request when Cef is shuting down?

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

How to send HTTP request when Cef is shuting down?

Postby BooU » Sat Aug 22, 2015 4:57 am

Hello,
I want to send http request at the same time when I call CefShutDown(), can anybody help me?
Sorry for my English, I hope you understand my problem.
BooU
Newbie
 
Posts: 3
Joined: Sat Aug 22, 2015 4:49 am

Re: How to send HTTP request when Cef is shuting down?

Postby magreenblatt » Sat Aug 22, 2015 8:58 pm

You would need to send the request and wait for it to complete before calling CefQuitMessageLoop/CefShutdown.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: How to send HTTP request when Cef is shuting down?

Postby BooU » Sun Aug 23, 2015 1:55 am

I tried that, but now I get this error, is it better to use libcur? I can't find the instructions how to add lib in VS2013...

Image
BooU
Newbie
 
Posts: 3
Joined: Sat Aug 22, 2015 4:49 am

Re: How to send HTTP request when Cef is shuting down?

Postby BooU » Mon Aug 24, 2015 1:17 pm

Does anybody know where should I add this code:

Code: Select all
CURL *curl;
    CURLcode res;

    curl = curl_easy_init();
    if (curl) {
        curl_easy_setopt(curl, CURLOPT_URL, "http://127.0.0.1:5000/");
        res = curl_easy_perform(curl);

        /* always cleanup */
        curl_easy_cleanup(curl);


if i want to call http://127.0.0.1:5000/ when Cef is shutting down ? Please help
BooU
Newbie
 
Posts: 3
Joined: Sat Aug 22, 2015 4:49 am


Return to Support Forum

Who is online

Users browsing this forum: delta42, Google [Bot], Majestic-12 [Bot] and 83 guests