Ali Baba said:
> i was just trying recursive function invocation and got a server crash
> when i changed a GUC variable max_stack_depth, to a high number.
> fallowing is what i have tried.
> select max_val from pg_settings where name='max_stack_depth'; --
> returns 2097151 set max_stack_depth=2097151;
> CREATE OR REPLACE FUNCTION func() RETURNS INT AS $$
> x int;
> x := func();
> return 0;
> $$ LANGUAGE PLPGSQL;
> select func();
> and the server get crashed.
> Any ideas?
what the heck did you expect with an infinitely recursive function?
In response to
pgsql-hackers by date
|Next:||From: Tom Lane||Date: 2006-06-01 01:55:33|
|Subject: Re: server crash on recursive function invocation |
|Previous:||From: David Hoksza||Date: 2006-05-31 22:10:28|
|Subject: Re: session id and global storage|