projects
/
pspp-builds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fixed buglet in file open action.
[pspp-builds.git]
/
src
/
language
/
dictionary
/
missing-values.c
diff --git
a/src/language/dictionary/missing-values.c
b/src/language/dictionary/missing-values.c
index 99018c3f4fe381ded138ccc0add09aa89df6cd51..6a5864a57c89f6dab9d2af348a6e9c3e375c113d 100644
(file)
--- a/
src/language/dictionary/missing-values.c
+++ b/
src/language/dictionary/missing-values.c
@@
-1,6
+1,5
@@
/* PSPP - computes sample statistics.
Copyright (C) 1997-9, 2000, 2006 Free Software Foundation, Inc.
/* 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
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License as
@@
-22,7
+21,9
@@
#include <stdlib.h>
#include <data/data-in.h>
#include <stdlib.h>
#include <data/data-in.h>
+#include <data/missing-values.h>
#include <data/procedure.h>
#include <data/procedure.h>
+#include <data/value.h>
#include <data/variable.h>
#include <language/command.h>
#include <language/lexer/lexer.h>
#include <data/variable.h>
#include <language/command.h>
#include <language/lexer/lexer.h>
@@
-133,20
+134,15
@@
cmd_missing_values (struct lexer *lexer, struct dataset *ds)
for (i = 0; i < nv; i++)
{
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;
}
{
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);
- }
}
}
}
}