Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] C puzzle
- Date: 31 Jul 2002 07:56:48 +0900
- From: bruno raoult <br@example.com>
- Subject: Re: [tlug] C puzzle
- References: <20020726012006.M48242-100000@example.com><15680.11598.642676.889439@example.com> <1027725222.13382.6.camel@example.com><m3d6t6xcn8.wl@example.com> <15685.61809.707516.99320@example.com><3D45F5AD.7030707@example.com> <1028034551.13418.130.camel@example.com><3D4693D2.1020208@example.com> <15686.45289.914784.491660@example.com> <20020730154745.GA2854@example.com>
My solution is shorter. And it crashes too :-) main; It compiles (with warning), then the loadder tries to call main, which is at address 0. segfault. br. On Wed, 2002-07-31 at 00:47, David Santinoli wrote: > On Tue, Jul 30, 2002 at 11:29:45AM -0400, Viktor Pavlenko wrote: > > > > What about the one which always crashes? > > > > The following program contains 25 characters, uses no library > > functions and segfaults when run: > > > > main(){((void(*)())0)();} > > echo 'main(){main();}' > f.c ; gcc -o f f.c ; ./f ; rm f.c f > > Sooner or later it *should* get out of stack space, shouldn't it? ;-) > > Ciao > David > > > ************************************************* > TLUG server is hosted by Global Online Japan > http://home.gol.com/index_e.html > ************************************************* > > ================================================= > To unsubscribe from this mailing list, > please see instructions at > http://www.tlug.jp/list.html > ================================================= > -- If it happens once, it's a bug. If it happens twice, it's a feature. If it happens more than twice, it's a design philosophy.Attachment: signature.asc
Description: This is a digitally signed message part
- References:
- [tlug] C puzzle
- From: Tod McQuillin
- Re: [tlug] C puzzle
- From: Viktor Pavlenko
- Re: [tlug] C puzzle
- From: bruno raoult
- Re: [tlug] C puzzle
- From: Masato BITO
- Re: [tlug] C puzzle
- From: Viktor Pavlenko
- Re: [tlug] C puzzle
- From: Josh Glover
- Re: [tlug] C puzzle
- From: bruno raoult
- Re: [tlug] C puzzle
- From: Josh Glover
- Re: [tlug] C puzzle
- From: Viktor Pavlenko
- Re: [tlug] C puzzle
- From: David Santinoli
Home | Main Index | Thread Index
- Prev by Date: OT: Mega Tokyo (was: Re: [tlug] Re: C puzzle)
- Next by Date: [tlug] Re: Mutt complaining of a read-only mailspool
- Previous by thread: Re: [tlug] C puzzle
- Next by thread: Re: [tlug] C puzzle
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links