This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Segfault of sys.setrecursionlimit if limit exceeds the value 18063 (GNU/Linux)
Type: crash Stage:
Components: Interpreter Core, Library (Lib) Versions: Python 2.5
process
Status: closed Resolution: wont fix
Dependencies: Superseder:
Assigned To: Nosy List: loewis, str1442
Priority: normal Keywords:

Created on 2009-06-28 09:51 by str1442, last changed 2022-04-11 14:56 by admin. This issue is now closed.

Messages (2)
msg89772 - (view) Author: str1442 (str1442) Date: 2009-06-28 09:51
After playing around with the setrecursionlimit() Function in the sys
module, i noticed it crashes if you set the limit to a value that is too
high. I explored this further until i noticed the value from which the
crashing begins is exactly 18063. I know that the highest setable value
is platformdependent, but crashing seems inappropriate if a value is
given that is too high.

I'm using Debian GNU/Linux Testing, last upgrade one month ago.

uname -svomr:

Linux 2.6.27.7 #4 SMP Fri Nov 28 01:44:17 CET 2008 i686 GNU/Linux

(Kernel is a pure kernel.org Kernel, self compiled)

Python Version in question is 2.5.4. Searching through the tracker for
setrecursionlimit brought no corresponding issues.

This is a the test script I used:

import sys

sys.setrecursionlimit(18063)

def f():
    g()

def g():
    f()

f()
msg89773 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2009-06-28 10:53
> I know that the highest setable value
> is platformdependent, but crashing seems inappropriate if a value is
> given that is too high.

No, it's not inappropriate. It's the only possible reaction.

Closing as won't fix.
History
Date User Action Args
2022-04-11 14:56:50adminsetgithub: 50605
2009-06-28 10:54:11loewissetstatus: open -> closed
resolution: wont fix
2009-06-28 10:53:55loewissetnosy: + loewis
title: Segfault of sys.setrecursionlimit if limit exceeds the value 18063 (GNU/Linux) -> Segfault of sys.setrecursionlimit if limit exceeds the value 18063 (GNU/Linux)
messages: + msg89773
2009-06-28 09:51:34str1442create