/* PSPP - a program for statistical analysis.
- Copyright (C) 2009 Free Software Foundation, Inc.
+ Copyright (C) 2009, 2010, 2011 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
#include <config.h>
-#include <libpspp/argv-parser.h>
+#include "libpspp/argv-parser.h"
#include <limits.h>
-#include <libpspp/assertion.h>
-#include <libpspp/str.h>
+#include "libpspp/assertion.h"
+#include "libpspp/str.h"
-#include "xalloc.h"
+#include "gl/xalloc.h"
struct argv_option_plus
{
ap->options = x2nrealloc (ap->options, &ap->allocated_options,
sizeof *ap->options);
+ assert (src->long_name != NULL || src->short_name != 0);
dst = &ap->options[ap->n_options++];
dst->base = *src;
dst->cb = cb;
if (shortopt_ptrs[c] == NULL)
{
shortopt_ptrs[c] = aop;
- ds_put_char (&shortopts, aop->base.short_name);
+ ds_put_byte (&shortopts, aop->base.short_name);
if (aop->base.has_arg != no_argument)
- ds_put_char (&shortopts, ':');
+ ds_put_byte (&shortopts, ':');
if (aop->base.has_arg == optional_argument)
- ds_put_char (&shortopts, ':');
+ ds_put_byte (&shortopts, ':');
}
else
{