From 04730852a0c96baa796ad3f1b52631daaa798977 Mon Sep 17 00:00:00 2001 From: Marco van Wieringen Date: Tue, 6 Apr 2010 22:29:50 +0200 Subject: [PATCH] Fix error introduced when refactoring some of the code. --- bacula/src/cats/myingres.c | 4 ++-- bacula/src/cats/myingres.sc | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bacula/src/cats/myingres.c b/bacula/src/cats/myingres.c index 42a7fbfd26..a52e9356d1 100644 --- a/bacula/src/cats/myingres.c +++ b/bacula/src/cats/myingres.c @@ -60,8 +60,8 @@ short INGgetCols(INGconn *dbconn, const char *query, bool transaction) short number = -1; IISQLDA *sqlda; - sqlda = (IISQLDA *)malloc(IISQDA_HEAD_SIZE + (number * IISQDA_VAR_SIZE)); - memset(sqlda, 0, (IISQDA_HEAD_SIZE + (number * IISQDA_VAR_SIZE))); + sqlda = (IISQLDA *)malloc(IISQDA_HEAD_SIZE + IISQDA_VAR_SIZE); + memset(sqlda, 0, (IISQDA_HEAD_SIZE + IISQDA_VAR_SIZE)); sqlda->sqln = number; stmt = bstrdup(query); /* diff --git a/bacula/src/cats/myingres.sc b/bacula/src/cats/myingres.sc index adebe2e6f0..ad19f91359 100644 --- a/bacula/src/cats/myingres.sc +++ b/bacula/src/cats/myingres.sc @@ -57,8 +57,8 @@ short INGgetCols(INGconn *dbconn, const char *query, bool transaction) short number = -1; IISQLDA *sqlda; - sqlda = (IISQLDA *)malloc(IISQDA_HEAD_SIZE + (number * IISQDA_VAR_SIZE)); - memset(sqlda, 0, (IISQDA_HEAD_SIZE + (number * IISQDA_VAR_SIZE))); + sqlda = (IISQLDA *)malloc(IISQDA_HEAD_SIZE + IISQDA_VAR_SIZE); + memset(sqlda, 0, (IISQDA_HEAD_SIZE + IISQDA_VAR_SIZE)); sqlda->sqln = number; -- 2.39.5