diff options
Diffstat (limited to 'src/interfaces/ecpg/compatlib/informix.c')
-rw-r--r-- | src/interfaces/ecpg/compatlib/informix.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/interfaces/ecpg/compatlib/informix.c b/src/interfaces/ecpg/compatlib/informix.c index 973d7a8547d..538aa3dc477 100644 --- a/src/interfaces/ecpg/compatlib/informix.c +++ b/src/interfaces/ecpg/compatlib/informix.c @@ -161,8 +161,7 @@ ecpg_strndup(const char *str, size_t len) int deccvasc(char *cp, int len, decimal * np) { - char *str = ecpg_strndup(cp, len); /* decimal_in always converts the - * complete string */ + char *str; int ret = 0; numeric *result; @@ -170,6 +169,7 @@ deccvasc(char *cp, int len, decimal * np) if (risnull(CSTRINGTYPE, cp)) return 0; + str = ecpg_strndup(cp, len); /* decimal_in always converts the complete string */ if (!str) ret = ECPG_INFORMIX_NUM_UNDERFLOW; else |