From: | Michael Meskes <meskes(at)postgresql(dot)org> |
---|---|
To: | Jürgen Cappel <email(at)juergen-cappel(dot)de> |
Cc: | pgsql-interfaces <pgsql-interfaces(at)postgresql(dot)org> |
Subject: | Re: ECPG Segfault and variable usage question. |
Date: | 2004-02-15 13:42:25 |
Message-ID: | 20040215134225.GA13602@1 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-interfaces |
On Thu, Feb 12, 2004 at 08:00:12PM +0100, Jürgen Cappel wrote:
> this is a code snippet that causes ECPG to segfault. It's quite tricky
I took this code as a.pgc and ran 'ecpg a.pgc' without any problem. Do
you use any special options for ecpg?
> Stack trace was obtained using a snapshot from about 2 weeks ago, ECPG from
> the 7.4.1 release segfaults also.
Hmm, my 7.4.1 version also compiles this snippet cleanly.
> Another problem that's giving me headaches trying to find a workaround for
> is the following use of variables as data sources in INSERT/UPDATE
> statements:
>
> :myarray[index[10]]
>
> Any comments, suggestions, hints ? Thanks a lot,
Could you please try if the following patch helps you?
--- /home/postgres/pgsql-ecpg/preproc/pgc.l 2003-12-29 14:53:04.000000000 +0100
+++ pgc.l 2004-02-15 14:38:43.000000000 +0100
@@ -183,7 +183,7 @@
identifier {ident_start}{ident_cont}*
-array ({ident_cont}|{whitespace}|[\+\-\*\%\/\(\)])*
+array ({ident_cont}|{whitespace}|[\[\]\+\-\*\%\/\(\)])*
typecast "::"
/*
This will make it into CVS soon.
Michael
--
Michael Meskes
Email: Michael at Fam-Meskes dot De
ICQ: 179140304, AIM/Yahoo: michaelmeskes, Jabber: meskes(at)jabber(dot)org
Go SF 49ers! Go Rhein Fire! Use Debian GNU/Linux! Use PostgreSQL!
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Meskes | 2004-02-15 13:43:21 | Re: ECPG Segfault and variable usage question. |
Previous Message | Edmund Bacon | 2004-02-13 16:07:34 | Re: ECPG Segfault and variable usage question. |