From: Nikos Mavrogiannopoulos Date: Thu, 24 Oct 2002 16:39:14 +0000 (+0000) Subject: gnutls-cli-debug now accepts one hostname only X-Git-Tag: gnutls_0_5_11~45 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f42c22c62e41809a2dfeb868ec7c8697552af02e;p=thirdparty%2Fgnutls.git gnutls-cli-debug now accepts one hostname only --- diff --git a/src/tls_test-gaa.c b/src/tls_test-gaa.c index 9bf2a7467b..774b7c1b9a 100644 --- a/src/tls_test-gaa.c +++ b/src/tls_test-gaa.c @@ -134,10 +134,8 @@ typedef struct _gaainfo gaainfo; struct _gaainfo { -#line 13 "tls_test.gaa" - char **rest_args; #line 12 "tls_test.gaa" - int nrest_args; + char *rest_args; #line 6 "tls_test.gaa" int more_info; #line 3 "tls_test.gaa" @@ -395,7 +393,7 @@ struct GAAOPTION_port struct GAAREST { - char** arg1; + char* arg1; int size1; }; @@ -498,9 +496,11 @@ int gaa_try(int gaa_num, int gaa_index, gaainfo *gaaval, char *opt_list) return GAA_OK; break; case GAA_REST: - GAA_LIST_FILL(GAAREST_tmp.arg1, gaa_getstr, char*, GAAREST_tmp.size1); -#line 14 "tls_test.gaa" -{ gaaval->rest_args = GAAREST_tmp.arg1; gaaval->nrest_args = GAAREST_tmp.size1 ;}; + GAA_TESTMOREARGS; + GAA_FILL(GAAREST_tmp.arg1, gaa_getstr, GAAREST_tmp.size1); + gaa_index++; +#line 13 "tls_test.gaa" +{ gaaval->rest_args = GAAREST_tmp.arg1; ;}; return GAA_OK; break; @@ -528,8 +528,8 @@ int gaa(int argc, char **argv, gaainfo *gaaval) if(inited == 0) { -#line 16 "tls_test.gaa" -{ gaaval->rest_args=NULL; gaaval->nrest_args=0; gaaval->pp = 443; gaaval->more_info = 0; ;}; +#line 15 "tls_test.gaa" +{ gaaval->rest_args=NULL; gaaval->pp = 443; gaaval->more_info = 0; ;}; } inited = 1; diff --git a/src/tls_test-gaa.h b/src/tls_test-gaa.h index fc1a63f75c..fe83e48989 100644 --- a/src/tls_test-gaa.h +++ b/src/tls_test-gaa.h @@ -8,10 +8,8 @@ typedef struct _gaainfo gaainfo; struct _gaainfo { -#line 13 "tls_test.gaa" - char **rest_args; #line 12 "tls_test.gaa" - int nrest_args; + char *rest_args; #line 6 "tls_test.gaa" int more_info; #line 3 "tls_test.gaa" diff --git a/src/tls_test.c b/src/tls_test.c index 07670a942e..8df3e6c6c9 100644 --- a/src/tls_test.c +++ b/src/tls_test.c @@ -217,8 +217,8 @@ void gaa_parser(int argc, char **argv) } port = info.pp; - if (info.nrest_args==0) hostname="localhost"; - else hostname = info.rest_args[0]; + if (info.rest_args==NULL) hostname="localhost"; + else hostname = info.rest_args; more_info = info.more_info; diff --git a/src/tls_test.gaa b/src/tls_test.gaa index c1d0664a69..bf3a059c24 100644 --- a/src/tls_test.gaa +++ b/src/tls_test.gaa @@ -9,9 +9,8 @@ option (v, verbose) { $more_info = 1 } "More verbose output" option (h, help) { gaa_help(); exit(0); } "prints this help" -#int nrest_args; -#char **rest_args; -rest *STR "hostname" { $rest_args = $1; $nrest_args = @1 } +#char *rest_args; +rest STR "hostname" { $rest_args = $1; } -init { $rest_args=NULL; $nrest_args=0; $pp = 443; $more_info = 0; } +init { $rest_args=NULL; $pp = 443; $more_info = 0; }