Segmentation fault in recursive function


#1

Hi,

when executing the attached code I get a segmentation fault.

I know the code does not make that much sense but nervertheless should
ruby never segfault but throw a SystemStackError or something similar.

I am using ruby 1.8.4 under Gentoo (powerpc). On a x86 computer the code
correctly throws a SystemStackError.

Greetings,
Sven


#2

Hi,

2006/4/13, Sven K. removed_email_address@domain.invalid:

I know the code does not make that much sense but nervertheless should
ruby never segfault but throw a SystemStackError or something similar.

I am using ruby 1.8.4 under Gentoo (powerpc). On a x86 computer the code
correctly throws a SystemStackError.

Stack overflow can’t be caught always. There’s no way (portable one,
at least) to tell it from other segfaults.