pspp-cvs
[Top][All Lists]
Advanced

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

[Pspp-cvs] Changes to pspp/src/t-test.q


From: Ben Pfaff
Subject: [Pspp-cvs] Changes to pspp/src/t-test.q
Date: Wed, 26 Oct 2005 01:07:58 -0400

Index: pspp/src/t-test.q
diff -u pspp/src/t-test.q:1.46 pspp/src/t-test.q:1.47
--- pspp/src/t-test.q:1.46      Mon Oct 24 02:51:31 2005
+++ pspp/src/t-test.q   Wed Oct 26 05:06:14 2005
@@ -310,8 +310,8 @@
          assert(cmd.n_variables == 0);
          cmd.n_variables = hsh_count(hash);
 
-         cmd.v_variables = xrealloc(cmd.v_variables,
-                                    sizeof(struct variable) * cmd.n_variables);
+         cmd.v_variables = xnrealloc (cmd.v_variables, cmd.n_variables,
+                                       sizeof *cmd.v_variables);
          /* Iterate through the hash */
          for (i=0,v = (struct variable *) hsh_first(hash,&hi);
               v != 0;
@@ -509,7 +509,7 @@
 
 
   /* Allocate storage for the pairs */
-  pairs = xrealloc(pairs, sizeof(struct pair) * (n_pairs + n_pairs_local) );
+  pairs = xnrealloc (pairs, n_pairs + n_pairs_local, sizeof *pairs);
 
   /* Populate the pairs with the appropriate variables */
   if ( paired ) 
@@ -1711,8 +1711,7 @@
       for (j=0 ; j < 2 ; ++j)
        {
 
-         struct group_statistics *gs = (struct group_statistics *) 
-           xmalloc (sizeof(struct group_statistics));
+         struct group_statistics *gs = xmalloc (sizeof *gs);
 
          gs->sum = 0;
          gs->n = 0;




reply via email to

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