-/* PSPP - computes sample statistics.
+/* PSPP - a program for statistical analysis.
Copyright (C) 1997-9, 2000, 2006 Free Software Foundation, Inc.
- This program is free software; you can redistribute it and/or
- modify it under the terms of the GNU General Public License as
- published by the Free Software Foundation; either version 2 of the
- License, or (at your option) any later version.
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
- This program is distributed in the hope that it will be useful, but
- WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
- 02110-1301, USA. */
+ along with this program. If not, see <http://www.gnu.org/licenses/>. */
#include <config.h>
#include "intprops.h"
#include "size_max.h"
+#include "xmalloca.h"
+
#include <data/casegrouper.h>
#include <data/casereader.h>
#include <data/dictionary.h>
#include <language/command.h>
#include <language/dictionary/split-file.h>
#include <language/lexer/lexer.h>
-#include <libpspp/alloc.h>
#include <libpspp/compiler.h>
-#include <libpspp/magic.h>
#include <libpspp/message.h>
#include <libpspp/message.h>
#include <libpspp/misc.h>
#include <output/table.h>
#include "minmax.h"
+#include "xalloc.h"
#include "gettext.h"
#define _(msgid) gettext (msgid)
return CMD_FAILURE;
/* Fill in defaults. */
- if (cmd.step == NOT_LONG)
+ if (cmd.step == LONG_MIN)
cmd.step = 1;
- if (cmd.first == NOT_LONG)
+ if (cmd.first == LONG_MIN)
cmd.first = 1;
- if (cmd.last == NOT_LONG)
+ if (cmd.last == LONG_MIN)
cmd.last = LONG_MAX;
if (!cmd.sbc_variables)
dict_get_vars (dict, &cmd.v_variables, &cmd.n_variables,
int line_number = 0;
const char *Line = _("Line");
- char *leader = local_alloc (strlen (Line)
- + INT_STRLEN_BOUND (line_number) + 1 + 1);
+ char *leader = xmalloca (strlen (Line)
+ + INT_STRLEN_BOUND (line_number) + 1 + 1);
while (index < cmd.n_variables)
{
d->cp_x = 0;
d->cp_y += d->font_height;
- local_free (leader);
+ freea (leader);
}
/* There are three possible layouts for the LIST procedure: