]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
gnutls-cli-debug now accepts one hostname only
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Thu, 24 Oct 2002 16:39:14 +0000 (16:39 +0000)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Thu, 24 Oct 2002 16:39:14 +0000 (16:39 +0000)
src/tls_test-gaa.c
src/tls_test-gaa.h
src/tls_test.c
src/tls_test.gaa

index 9bf2a7467b4902081b230d2c2dcdd93337f68d5a..774b7c1b9aae4cb633b9509b5e9bae31349abfb3 100644 (file)
@@ -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;
index fc1a63f75c7f9298f7a0d01d0669d6bf6072dd43..fe83e489896c6d9c37f63cec5fdb05972955c729 100644 (file)
@@ -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"
index 07670a942e644d3719376e181b75159331868b1c..8df3e6c6c9018f7accf4562d86fc6d4287e9b08f 100644 (file)
@@ -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;
        
index c1d0664a690fbe30a0cc0f94d1481b24247aaf35..bf3a059c24f204e3c5cf9d7cd1aa7e7ec0f4630b 100644 (file)
@@ -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; }