diff options
author | Michael Meskes <meskes@postgresql.org> | 2003-07-17 07:54:29 +0000 |
---|---|---|
committer | Michael Meskes <meskes@postgresql.org> | 2003-07-17 07:54:29 +0000 |
commit | 7d32551a81adcda190e1754fefed05acdbf49101 (patch) | |
tree | b6b6b5e1a44dfd0e77aa333793ca4efe14d61870 /src/interfaces/ecpg/compatlib/informix.c | |
parent | 764f72dc823edb3f8bdf387501ce4c12dedd2369 (diff) | |
download | postgresql-7d32551a81adcda190e1754fefed05acdbf49101.tar.gz postgresql-7d32551a81adcda190e1754fefed05acdbf49101.zip |
Fixed some bugs in Informix compat functions.
Diffstat (limited to 'src/interfaces/ecpg/compatlib/informix.c')
-rw-r--r-- | src/interfaces/ecpg/compatlib/informix.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/interfaces/ecpg/compatlib/informix.c b/src/interfaces/ecpg/compatlib/informix.c index d60019f68f9..807349fd835 100644 --- a/src/interfaces/ecpg/compatlib/informix.c +++ b/src/interfaces/ecpg/compatlib/informix.c @@ -443,7 +443,12 @@ rtoday (Date *d) int rjulmdy (Date d, short mdy[3]) { - PGTYPESdate_julmdy(d, (int *)mdy); + int mdy_int[3]; + + PGTYPESdate_julmdy(d, mdy_int); + mdy[0] = (short)mdy_int[0]; + mdy[1] = (short)mdy_int[1]; + mdy[2] = (short)mdy_int[2]; return 0; } @@ -482,7 +487,12 @@ rfmtdate (Date d, char *fmt, char *str) int rmdyjul (short mdy[3], Date *d) { - PGTYPESdate_mdyjul((int *)mdy, d); + int mdy_int[3]; + + mdy_int[0] = mdy[0]; + mdy_int[1] = mdy[1]; + mdy_int[2] = mdy[2]; + PGTYPESdate_mdyjul(mdy_int, d); return 0; } |