Re: Multiple request version for showtags.c

Thank you for you advise. And I am using linux. :)
But I found something maybe important:

**************************************************************************************************************************
void

fetch (const char * url)

{

    char * uri = NULL;

    uri = HTParse(url, NULL, PARSE_ALL);

    if (uri) {

       HTRequest * request = NULL;

       HTAnchor * anchor = NULL;

       BOOL status = NO;

       request = HTRequest_new();

//     HTRequest_setPreemptive(request, YES);

       anchor = HTAnchor_findAddress(uri);

//    I use gdb to debug the problem. I found when the application get a SIGSEGV:

//    (gdb) print *anchor

//    Cannot access memory at address 0xffffffe0

//    So can anyone tell me about the an anchor's life time?


        status = HTLoadAnchor(anchor, request);

       if (status == YES) HTEventList_loop(request);

    }

    HT_FREE(uri);

    return;

}





**************************************************************************************************************************
----- Original Message ----- 
From: "Richard Atterer" <richard@list03.atterer.net>
To: "Michael Qiu" <michael@atlas-china.com>
Sent: Thursday, February 20, 2003 5:01 AM
Subject: Re: Multiple request version for showtags.c


> On Mon, Feb 17, 2003 at 02:19:44PM +0800, Michael Qiu wrote:
> > Here is my module. It works in most time. But as the time goes by, It
> > will caught a SIGSEGV signal. Seems like I have make some mistake in
> > memory. Can anybody help me?
> 
> I would have advised you to run your program under the supervision of
> "valgrind" - IMHO the most useful program ever to detect such problems. 
> However, valgrind is only available for Linux, and you seem to be using 
> Windows(?).
> 
> But you can use a standard debugger to localize the exact place where it's
> crashing.
> 
> Cheers,
> 
>   Richard
> 
> -- 
>   __   _
>   |_) /|  Richard Atterer     |  CS student at the Technische  |  GnuPG key:
>   | \/¯|  http://atterer.net  |  Universität München, Germany  |  0x888354F7
>   ¯ '` ¯

Received on Wednesday, 19 February 2003 22:16:48 UTC