aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/ecpg/compatlib/informix.c
diff options
context:
space:
mode:
authorMichael Meskes <meskes@postgresql.org>2003-07-02 07:57:36 +0000
committerMichael Meskes <meskes@postgresql.org>2003-07-02 07:57:36 +0000
commit7b1885bf989781b12bda847b98c89476efb894c9 (patch)
tree234fa43ed5e0f2c216eec51b462e59521c28e743 /src/interfaces/ecpg/compatlib/informix.c
parentb837c99210697765e9c4589755a514cf5a0a8eec (diff)
downloadpostgresql-7b1885bf989781b12bda847b98c89476efb894c9.tar.gz
postgresql-7b1885bf989781b12bda847b98c89476efb894c9.zip
Fixed initialization bug and added postgres_fe.h to pgtypeslib.
Diffstat (limited to 'src/interfaces/ecpg/compatlib/informix.c')
-rw-r--r--src/interfaces/ecpg/compatlib/informix.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/interfaces/ecpg/compatlib/informix.c b/src/interfaces/ecpg/compatlib/informix.c
index 889faf54409..157809de22f 100644
--- a/src/interfaces/ecpg/compatlib/informix.c
+++ b/src/interfaces/ecpg/compatlib/informix.c
@@ -287,7 +287,10 @@ int
dectoasc(Decimal *np, char *cp, int len, int right)
{
char *str;
- Numeric *nres;
+ Numeric *nres = PGTYPESnumeric_new();
+
+ if (nres == NULL)
+ return -1211;
if (PGTYPESnumeric_from_decimal(np, nres) != 0)
return -1211;