tinycc-devel
[Top][All Lists]
Advanced

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

Re: [Tinycc-devel] Bug in tcc


From: Bernhard Fischer
Subject: Re: [Tinycc-devel] Bug in tcc
Date: Wed, 28 Sep 2005 20:41:28 +0200
User-agent: Mutt/1.5.9i

On Wed, Sep 28, 2005 at 09:36:02AM +0200, Sven Oliver Moll wrote:
>On Wed, 28 Sep 2005, PerfectDark wrote:
>
>>>>>Just try to compile (tcc -c) following file:
>>>>>
>>>>>//-------------------------------------------
>>>>>//begin
>>>>>void foo(SomethingUnknownType* x)
>>>>>{
>>>>>}
>>>>>//end
>>>>>//-------------------------------------------
>[...]
>>
>>May be all that bugs (see my next ask in list) because I use non-patched 
>>tcc (tcc-0.9.23), or windows version has something bug...
>>
>>Even though I could compile tcc by tcc and simple windows applications 
>>(GDI and console). Tcc crushes if it meet that code (see my question).
>>
>>If you know how I can fix it, tell me please.

Can you try the attached patch, please an let me know if it fixed that
particular thing?

thanks,
>>
>
>This seems to be a bug in tcc itself, not the Windows port. I ran it on a
>Linux system and got the following:
>
>$ gdb tcc-0.9.23/tcc
>GNU gdb 6.3
>[...]
>This GDB was configured as "i686-pc-linux-gnu"...Using host libthread_db 
>library "/lib/libthread_db.so.1".
>
>(gdb) run -c foo.c
>Starting program: /home/svolli/tcc/tcc-0.9.23/tcc -c foo.c
>
>Program received signal SIGSEGV, Segmentation fault.
>0x0804bc2f in sym_push (v=42, type=0x80804ac, r=498, c=12) at tcc.c:1766
>1766            s->prev_tok = *ps;
>(gdb) quit
>The program is running.  Exit anyway? (y or n) y
>$ cat foo.c
>void foo(unknown *x)
>{
>}
>
>I'd say that ps is NULL in this case, but that's a rough guess.
>Hope this helps.
>
>Greetings from Germany,
>SvOlli
>-- 
>|  _______       |
>| (  /\          | There's no feeling any greater
>|__)v\/lli a.k.a.| Than to shoot first and ask questions later
>|Sven Oliver Moll|   -- "Weird Al" Yankovic, "Trigger Happy"
>
>
>_______________________________________________
>Tinycc-devel mailing list
>address@hidden
>http://lists.nongnu.org/mailman/listinfo/tinycc-devel
>

Attachment: tinycc.fix-segfault-in-skip.diff
Description: Text document


reply via email to

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