We Jul 5 12:17:28 CEST 2006
- - Fixed remaining Coverity bugs.
+ - Fixed most of the remaining Coverity bugs.
Fr Jul 28 11:00:51 CEST 2006
- SHOW statement puts result into a variable
- COPY TO STDOUT works
- Connection identifier has to be unique
+ - Variables should be free'ed only once.
- Set ecpg library version to 5.2.
- Set ecpg version to 4.2.1.
-/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/execute.c,v 1.54 2006/07/28 10:12:56 meskes Exp $ */
+/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/execute.c,v 1.55 2006/07/28 11:49:36 meskes Exp $ */
/*
* The aim is to get a simpler inteface to the database routines.
case ECPGt_timestamp:
{
- char *str = NULL, *asc = NULL;
+ char *str = NULL;
int slen;
if (var->arrsize > 1)
{
for (element = 0; element < var->arrsize; element++)
{
- asc = PGTYPEStimestamp_to_asc(*(timestamp *) ((var + var->offset * element)->value));
- if (!asc)
- return false;
-
- str = quote_postgres(asc, lineno);
- ECPGfree(asc); /* we don't need this anymore so free it asap. */
+ str = quote_postgres(PGTYPEStimestamp_to_asc(*(timestamp *) ((var + var->offset * element)->value)), lineno);
if (!str)
return false;
}
else
{
- asc = PGTYPEStimestamp_to_asc(*(timestamp *) (var->value));
- if (!asc)
- return false;
-
- str = quote_postgres(asc, lineno);
- ECPGfree(asc); /* we don't need this anymore so free it asap. */
+ str = quote_postgres(PGTYPEStimestamp_to_asc(*(timestamp *) (var->value)), lineno);
if (!str)
return false;
slen = strlen(str);