t-test: Remove write-only variable.
[pspp-builds.git] / src / language / stats / t-test.q
index 5f5fc56f021d1ba60d125a8b23561b6dae79031b..52f9838b4a2117d8351a9d23f1c760196e36a246 100644 (file)
@@ -242,9 +242,6 @@ static  int mode;
 
 static struct cmd_t_test cmd;
 
-static bool bad_weight_warn = false;
-
-
 static int compare_group_binary (const struct group_statistics *a,
                                const struct group_statistics *b,
                                const struct group_properties *p);
@@ -338,8 +335,6 @@ cmd_t_test (struct lexer *lexer, struct dataset *ds)
       return CMD_FAILURE;
     }
 
-  bad_weight_warn = true;
-
   /* Data pass. */
   grouper = casegrouper_create_splits (proc_open (ds), dataset_dict (ds));
   while (casegrouper_get_next_group (grouper, &group))
@@ -749,15 +744,15 @@ ssbox_independent_samples_populate (struct ssbox *ssb,
       const char *s;
 
       s = var_lookup_value_label (indep_var, &gp.v.g_value[0]);
-      val_lab[0] = s ? strdup (s) : NULL;
+      val_lab[0] = s ? xstrdup (s) : NULL;
 
       s = var_lookup_value_label (indep_var, &gp.v.g_value[1]);
-      val_lab[1] = s ? strdup (s) : NULL;
+      val_lab[1] = s ? xstrdup (s) : NULL;
     }
   else
     {
-      val_lab[0] = calloc (sizeof (char), MAX_SHORT_STRING + 1);
-      val_lab[1] = calloc (sizeof (char), MAX_SHORT_STRING + 1);
+      val_lab[0] = xcalloc (sizeof (char), MAX_SHORT_STRING + 1);
+      val_lab[1] = xcalloc (sizeof (char), MAX_SHORT_STRING + 1);
       memcpy (val_lab[0], gp.v.g_value[0].s, MAX_SHORT_STRING);
       memcpy (val_lab[1], gp.v.g_value[1].s, MAX_SHORT_STRING);
     }