FW: HTLoadToChunk() will block for a long period

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

FW: HTLoadToChunk() will block for a long period

Eric Liu-6

Hi, folks:

    if (url) {
        char * cwd = HTGetCurrentDirectoryURL();
        char * absolute_url = HTParse(url, cwd, PARSE_ALL);
        chunk = HTLoadToChunk(absolute_url, request);
        HT_FREE(absolute_url);
        HT_FREE(cwd);
 }


Using the above code from the chunk.c exmaple, is it possible to set a timeout on the request without using an event loop? If the target server is not responding then the call HTLoadToChunk() will block for a long period.
Is there a simple function to set a timeout, I can't seem to find one in the documentation.



Thanks and Regards
Eric