#include <config.h>
#endif
+#include <sysexits.h>
+
#include "argp.h"
/* The exit status that argp will use when exiting due to a parsing error.
- If not defined or set by the user program, this defaults to 1. */
-error_t argp_err_exit_status = 1;
+ If not defined or set by the user program, this defaults to EX_USAGE from
+ <sysexits.h>. */
+error_t argp_err_exit_status = EX_USAGE;
{
int non_opt;
/* Skip initial whitespace. */
- while (isspace (*name))
+ while (isspace (**name))
(*name)++;
/* Decide whether this looks like an option (leading `-') or not. */
non_opt = (**name != '-');
/* Skip until part of name used for sorting. */
- while (**name && !isalnum (*name))
+ while (**name && !isalnum (**name))
(*name)++;
return non_opt;
}
\f
/* If appropriate, print the printf string FMT and following args, preceded
by the program name and `:', to stderr, and followed by a `Try ... --help'
- message, then exit (ARGP_ERR_EXIT_STATUS). */
+ message, then exit (1). */
void
__argp_error (const struct argp_state *state, const char *fmt, ...)
{
#ifndef __error_t_defined
typedef int error_t;
+#define __error_t_defined
#endif
#ifndef __P
__const extern char *argp_program_bug_address;
/* The exit status that argp will use when exiting due to a parsing error.
- If not defined or set by the user program, this defaults to 1. */
+ If not defined or set by the user program, this defaults to EX_USAGE from
+ <sysexits.h>. */
extern error_t argp_err_exit_status;
\f
/* Flags for argp_help. */
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
*:GNU:*:*)
- echo `echo ${UNAME_MACHINE}|sed -e 's,-.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
+ echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit 0 ;;
*:Linux:*:*)
# The BFD linker knows what the default object file format is, so
#include <assert.h>
jmp_buf _hurdsig_fault_env;
-struct hurd_signal_preemptor _hurdsig_fault_preemptor;
+struct hurd_signal_preemptor _hurdsig_fault_preemptor = {0};
/* XXX temporary to deal with spelling fix */
weak_alias (_hurdsig_fault_preemptor, _hurdsig_fault_preempter)
}
}
-struct hurd_signal_preemptor *_hurdsig_preemptors;
+struct hurd_signal_preemptor *_hurdsig_preemptors = 0;
sigset_t _hurdsig_preempted_set;
/* XXX temporary to deal with spelling fix */