X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=tests%2Ftest-argp.c;h=8fab727c9ae55f31a36fbdff7450ea129f6fc5d2;hb=17857d41b41e7b22ba58e4e0d98693ee14f022d4;hp=7da426f066167835de9d75a298b97dbd3e13d50c;hpb=d60f3b0c6b0f93a601acd1cfd3923f94ca05abb0;p=gnulib.git diff --git a/tests/test-argp.c b/tests/test-argp.c index 7da426f06..8fab727c9 100644 --- a/tests/test-argp.c +++ b/tests/test-argp.c @@ -21,9 +21,7 @@ #include #include -#if HAVE_STRING_H -# include -#endif +#include #if HAVE_STRINGS_H # include #endif @@ -228,7 +226,7 @@ parse_opt (int key, char *arg, struct argp_state *state) { case ARGP_KEY_INIT: for (i = 0; state->root_argp->children[i].argp; i++) - state->child_inputs[i] = args; + state->child_inputs[i] = args; break; case 't': @@ -348,7 +346,7 @@ test6 (struct argp *argp) void test_optional (struct argp *argp, int argc, char **argv, - struct test_args *args, const char *val, const char *a) + struct test_args *args, const char *val, const char *a) { int index; if (argp_parse (argp, argc, argv, 0, &index, args)) @@ -359,7 +357,7 @@ test_optional (struct argp *argp, int argc, char **argv, if (!val) { if (args->optional) - fail ("option processed incorrectly"); + fail ("option processed incorrectly"); } else if (strcmp (args->optional, val)) fail ("option processed incorrectly"); @@ -367,9 +365,9 @@ test_optional (struct argp *argp, int argc, char **argv, if (a) { if (index == argc) - fail ("expected command line argument not found"); + fail ("expected command line argument not found"); else if (strcmp (argv[index], a)) - fail ("expected command line argument does not match"); + fail ("expected command line argument does not match"); } }