Skip site navigation (1) Skip section navigation (2)

BUG #2981: server crash

From: "Asif" <asifalirehman(at)gmail(dot)com>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #2981: server crash
Date: 2007-02-07 18:47:28
Message-ID: 200702071847.l17IlSWe088241@wwwmaster.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-bugs
The following bug has been logged online:

Bug reference:      2981
Logged by:          Asif
Email address:      asifalirehman(at)gmail(dot)com
PostgreSQL version: 8.2.1
Operating system:   Fedora 3
Description:        server crash
Details: 

I have compiled postgres 8.2.1 with gcc 4.1. and when executed this function
it crashes the server.

Steps to produce
----------------
CREATE  OR REPLACE FUNCTION func2() RETURNS int as $$
BEGIN
    RAISE EXCEPTION 'ex -----';
    EXCEPTION
    WHEN OTHERS THEN
    RAISE INFO 'sql error msg %',sqlerrm;
    DECLARE
    v_msg VARCHAR(200) := sqlerrm;
    BEGIN    
        RAISE INFO 'sql error msg %',sqlerrm;
      ENd;
RETURN 0;
END;
$$ LANGUAGE plpgsql;

select func2();


Output
------
INFO:  sql error msg ex -----
server closed the connection unexpectedly
        This probably means the server terminated abnormally
        before or while processing the request.
The connection to the server was lost. Attempting reset: Failed.

pgsql-bugs by date

Next:From: rob_spellbergDate: 2007-02-07 20:05:27
Subject: ah, the irony - an html error on the pgsql-bugs web page
Previous:From: Marcio A. SeppDate: 2007-02-07 16:37:41
Subject: ENC: Possible problem with type bigserial in pg_dump/pg_restore

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group