diff options
Diffstat (limited to 'src/interfaces/ecpg/ecpglib/misc.c')
-rw-r--r-- | src/interfaces/ecpg/ecpglib/misc.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/interfaces/ecpg/ecpglib/misc.c b/src/interfaces/ecpg/ecpglib/misc.c index ee0d3e98fb9..02338a41eae 100644 --- a/src/interfaces/ecpg/ecpglib/misc.c +++ b/src/interfaces/ecpg/ecpglib/misc.c @@ -355,6 +355,9 @@ ECPGset_noind_null(enum ECPGttype type, void *ptr) *(((struct ECPGgeneric_varchar *) ptr)->arr) = 0x00; ((struct ECPGgeneric_varchar *) ptr)->len = 0; break; + case ECPGt_bytea: + ((struct ECPGgeneric_bytea *) ptr)->len = 0; + break; case ECPGt_decimal: memset((char *) ptr, 0, sizeof(decimal)); ((decimal *) ptr)->sign = NUMERIC_NULL; @@ -428,6 +431,10 @@ ECPGis_noind_null(enum ECPGttype type, const void *ptr) if (*(((const struct ECPGgeneric_varchar *) ptr)->arr) == 0x00) return true; break; + case ECPGt_bytea: + if (((struct ECPGgeneric_bytea *) ptr)->len == 0) + return true; + break; case ECPGt_decimal: if (((const decimal *) ptr)->sign == NUMERIC_NULL) return true; |