lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

LYNX-DEV latest development code: linux alpha sigsegv - token fix


From: uid no body
Subject: LYNX-DEV latest development code: linux alpha sigsegv - token fix
Date: Tue, 22 Jul 1997 16:17:58 -0400

I got a sigsev, and tracked it to strtok call.  Apparently if strtok
returns NULL, it should not be called again on linux-alpha.  The fix is
near 6440 of src/HTML.c by inserting the "if( cp )":

            cp = strtok(me->textarea.data, "\n");
            LYUnEscapeEntities(cp, me->UsePlainSpace, me->HiddenValue);
            for (i = 0; i < me->textarea_rows; i++) {
                I.value = cp;

                chars = HText_beginInput(me->text, me->inUnderline, &I);
                for (; chars > 0; chars--)
                    HTML_put_character(me, '_');
                HText_appendCharacter(me->text, '\r');

if( cp )
                cp = strtok(NULL, "\n");
                LYUnEscapeEntities(cp, me->UsePlainSpace, me->HiddenValue);
            }


Program received signal SIGSEGV, Segmentation fault.
0x15555934140 in strspn ()
(gdb) bt
#0  0x15555934140 in strspn ()
#1  0x1555593437c in strtok ()
#2  0x12006db7c in HTML_end_element () at ./HTML.c:6440
#3  0x1200a5650 in end_element () at
../../Library/Implementation/SGML.c:716
#4  0x1200a695c in SGML_character () at
../../Library/Implementation/SGML.c:1323
#5  0x1200a8e5c in SGML_write () at
../../Library/Implementation/SGML.c:2489
#6  0x1200b5574 in HTMIME_write () at
../../Library/Implementation/HTMIME.c:2035
#7  0x1200b0f54 in HTCopy () at
../../Library/Implementation/HTFormat.c:560
#8  0x120096558 in HTLoadHTTP () at
../../Library/Implementation/HTTP.c:1623
#9  0x1200920c4 in HTLoad () at
../../Library/Implementation/HTAccess.c:559
#10 0x12009254c in HTLoadDocument () at
../../Library/Implementation/HTAccess.c:736
#11 0x120092b1c in HTLoadAbsolute () at
../../Library/Implementation/HTAccess.c:903
#12 0x1200294bc in getfile () at ./LYGetFile.c:685
#13 0x12003071c in mainloop () at ./LYMainLoop.c:470
#14 0x12002cdf8 in main () at ./LYMain.c:1628


--- reply to tzeruch - at - ceddec - dot - com ---



;
; To UNSUBSCRIBE:  Send a mail message to address@hidden
;                  with "unsubscribe lynx-dev" (without the
;                  quotation marks) on a line by itself.
;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]