optional (0of or 1of) with "[+]" semantics.
authorLuke Leighton <lkcl@samba.org>
Sat, 27 May 2000 11:08:05 +0000 (11:08 +0000)
committerLuke Leighton <lkcl@samba.org>
Sat, 27 May 2000 11:08:05 +0000 (11:08 +0000)
(This used to be commit 55a3e4b5922eff4110970a2ed2372c431ac70918)

source3/aparser/cifs.struct
source3/aparser/parsefn.awk

index 7274ce60f6b15f44adf8aaca3c3419a953661a2e..d3cee42e68e639ef2a1c865962fa8bbb271da397 100644 (file)
@@ -101,7 +101,7 @@ typedef struct {
                              /*  security package if CAP_EXTENDED_SECURITY is */
                              /*  on in the Capabilities field; else challenge */
                              /*  for CIFS challenge/response authentication. */
-       string OemDomainName; /*The name of the domain (in OEM chars); not */
+       string OemDomainName[+]; /*The name of the domain (in OEM chars); not */
                              /*  present  if CAP_EXTENDED_SECURITY is on in the */
                              /*  Capabilities field */
 } R_NEGPROT_17;
index bff4521ba63b171dcf2436f68f0db40f4f0bd769..8d8f8103192428024d5bfed512c4d0fdf5611319 100644 (file)
@@ -16,6 +16,11 @@ function parse_array(f, v, elnum, flags,
        v["FLAGS"] = flags;
        v["ARRAY_LEN"] = array_len;
 
+       if (array_len=="+") {
+         print_template(f,"prs_array_optional.tpl", v);
+         return;
+       }
+
        if (array_len=="*") {
          print_template(f,"prs_array_remainder.tpl", v);
          return;