very stupid calloc typo
authorJan Pospíšil <honik@ntc.zcu.cz>
Wed, 20 Sep 2006 08:35:07 +0000 (08:35 +0000)
committerJan Pospíšil <honik@ntc.zcu.cz>
Wed, 20 Sep 2006 08:35:07 +0000 (08:35 +0000)
org.glite.lb.server/src/lb_plugin.c

index 5a49214..fb3b08a 100644 (file)
@@ -529,7 +529,7 @@ static int lb_query(void *fpctx,void *handle,const char *attr,glite_jp_attrval_t
 
                val = s_str = t_str = r_str = NULL;
                old_val = strdup("");
-               t = calloc(1, sizeof(t));
+               t = calloc(1, sizeof(*t));
                /* first record is Submitted - hopefully in fullStatusHistory[0] */
                if ((h->fullStatusHistory[0] && 
                        (h->fullStatusHistory[0]->state == EDG_WLL_JOB_SUBMITTED)) ) {
@@ -597,7 +597,7 @@ static int lb_query(void *fpctx,void *handle,const char *attr,glite_jp_attrval_t
 
                val = s_str = t_str = r_str = NULL;
                old_val = strdup("");
-               t = calloc(1, sizeof(t));
+               t = calloc(1, sizeof(*t));
                i = 0;
                while (h->fullStatusHistory[i]) {
                        s_str = edg_wll_StatToString(h->fullStatusHistory[i]->state);