pspp-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pspp-cvs] Changes to pspp/src/descript.c


From: Ben Pfaff
Subject: [Pspp-cvs] Changes to pspp/src/descript.c
Date: Wed, 26 Oct 2005 01:06:44 -0400

Index: pspp/src/descript.c
diff -u pspp/src/descript.c:1.16 pspp/src/descript.c:1.17
--- pspp/src/descript.c:1.16    Mon Oct 24 02:51:32 2005
+++ pspp/src/descript.c Wed Oct 26 05:06:14 2005
@@ -311,7 +311,7 @@
                                     PV_APPEND | PV_NO_DUPLICATE | PV_NUMERIC))
                goto error;
 
-              dsc->vars = xrealloc (dsc->vars, sizeof *dsc->vars * var_cnt);
+              dsc->vars = xnrealloc (dsc->vars, var_cnt, sizeof *dsc->vars);
               for (i = dsc->var_cnt; i < var_cnt; i++)
                 {
                   struct dsc_var *dv = &dsc->vars[i];
@@ -634,14 +634,14 @@
   t = xmalloc (sizeof *t);
   t->h.proc = descriptives_trns_proc;
   t->h.free = descriptives_trns_free;
-  t->z_scores = xmalloc (cnt * sizeof *t->z_scores);
+  t->z_scores = xnmalloc (cnt, sizeof *t->z_scores);
   t->z_score_cnt = cnt;
   t->missing_type = dsc->missing_type;
   t->include_user_missing = dsc->include_user_missing;
   if ( t->missing_type == DSC_LISTWISE )
     {
       t->var_cnt = dsc->var_cnt;
-      t->vars = xmalloc(t->var_cnt * sizeof *t->vars);
+      t->vars = xnmalloc (t->var_cnt, sizeof *t->vars);
       for (i = 0; i < t->var_cnt; i++)
        t->vars[i] = dsc->vars[i].v;
     }




reply via email to

[Prev in Thread] Current Thread [Next in Thread]