/* PSPP - computes sample statistics.
Copyright (C) 1997-9, 2000, 2006 Free Software Foundation, Inc.
- Written by Ben Pfaff <blp@gnu.org>.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
#include <stdlib.h>
#include <data/data-in.h>
+#include <data/missing-values.h>
#include <data/procedure.h>
+#include <data/value.h>
#include <data/variable.h>
#include <language/command.h>
#include <language/lexer/lexer.h>
for (i = 0; i < nv; i++)
{
- if (!mv_is_resizable (&mv, var_get_width (v[i])))
+ if (mv_is_resizable (&mv, var_get_width (v[i])))
+ var_set_missing_values (v[i], &mv);
+ else
{
msg (SE, _("Missing values provided are too long to assign "
"to variable of width %d."),
var_get_width (v[i]));
deferred_errors = true;
}
- else
- {
- struct missing_values tmp;
- mv_copy (&tmp, &mv);
- mv_resize (&tmp, var_get_width (v[i]));
- var_set_missing_values (v[i], &tmp);
- }
}
}