[SCM] Samba Shared Repository - branch master updated

Jeremy Allison jra at samba.org
Tue Apr 3 21:09:01 UTC 2018


The branch, master has been updated
       via  5ebb1dd wafsamba: Add missing cflags_end argument to SAMBA_BINARY
       via  3e0f538 s3:modules: Set -Wno-strict-overflow for getdate if supported
       via  08e350b replace: Check for -Wno-strict-overflow
       via  a12e12e wafsamba: Add missing cflags_end argument to SAMBA_MODULE
       via  083e52f s3:modules: Generate new getdate.c with bison
       via  23bedb3 s3:modules: Update getdate.y to work with newer bison versions
       via  deccc84 s3:torture: Fix size types in make_nonstd_fd()
       via  be4cb4a s3:client: Fix size types
       via  22a28ac s3:spoolss: Fix size types
       via  0459a29 s3:printing: Fix size types
       via  0694015 s3:smbd: Fix size types in reply_negprot()
       via  abc9c56 s4:torture: Fix size types in torture_create_procs()
       via  aa17db1 heimdal: Fix size types and array access
       via  28dec65 s4:client: Fix size types and loop
       via  c4a73cc s4:registry: Fix size type and loop
       via  bc3834d lib:util: Fix size types in fgets_slash()
       via  4189504 third_party: Fix size type in cmocka
       via  889d1da ldb: Fix overflow checks
       via  be709e8 ldb: Add test for ldb_qsort()
       via  63e0532 third_party: Update pam_wrapper to version 1.0.6
      from  702665c s3:modules: fix the build of vfs_aixacl2.c

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 5ebb1dd18e58df1ea5da20bc34d9900290ada65f
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 10:52:54 2018 +0100

    wafsamba: Add missing cflags_end argument to SAMBA_BINARY
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>
    
    Autobuild-User(master): Jeremy Allison <jra at samba.org>
    Autobuild-Date(master): Tue Apr  3 23:08:33 CEST 2018 on sn-devel-144

commit 3e0f538c74edc79fe579049c0cafd915067e9bf9
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 10:18:17 2018 +0100

    s3:modules: Set -Wno-strict-overflow for getdate if supported
    
    bison generates an C89 files which does some weired things.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 08e350b54f5673d34fbaa1e566307187f16b20c6
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 16:27:00 2018 +0100

    replace: Check for -Wno-strict-overflow
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit a12e12e98684d6928f888a81088987d85bc2ed45
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 10:14:50 2018 +0100

    wafsamba: Add missing cflags_end argument to SAMBA_MODULE
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 083e52f5612c03f1b1741a953b74281457548289
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 09:30:27 2018 +0100

    s3:modules: Generate new getdate.c with bison
    
    bison -o source3/modules/getdate.c source3/modules/getdate.y<Paste>
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Alexander Bokovoy <ab at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 23bedb334daeeed46f2047bf383aa11545407f57
Author: Andreas Schneider <asn at samba.org>
Date:   Fri Mar 23 09:29:55 2018 +0100

    s3:modules: Update getdate.y to work with newer bison versions
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Alexander Bokovoy <ab at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit deccc84b73b0fa550cdf28a5fd4569d1a8477679
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 18:36:13 2018 +0100

    s3:torture: Fix size types in make_nonstd_fd()
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit be4cb4a70bb033f649a5cb272d104e967a6deab3
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 14:51:28 2018 +0100

    s3:client: Fix size types
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 22a28ac8acb44d88d866eb29af6b1161d1013d48
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 14:06:34 2018 +0100

    s3:spoolss: Fix size types
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 0459a2968fe4d39444f3a0cd8ccba8eeea19fd47
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 13:41:39 2018 +0100

    s3:printing: Fix size types
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 06940155f315529c5b523f8bacdaf60036254bdc
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 11:49:18 2018 +0100

    s3:smbd: Fix size types in reply_negprot()
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit abc9c56021db877a23f934805df0589d7a1b99f4
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 17:46:30 2018 +0100

    s4:torture: Fix size types in torture_create_procs()
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit aa17db1f4061920512396032fcd3c7c8a4a8f38f
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 13:02:26 2018 +0100

    heimdal: Fix size types and array access
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 28dec65cc26c4b53c1e1c9077edcdb540fb29551
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 10:28:02 2018 +0100

    s4:client: Fix size types and loop
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit c4a73ccd8f23eceae3ee598d9841860e7342230d
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 16:46:49 2018 +0100

    s4:registry: Fix size type and loop
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit bc3834d6910c71159ee5e6dc3b04475706d9e846
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 12:49:38 2018 +0100

    lib:util: Fix size types in fgets_slash()
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 41895045bae5f71e964d767ce676172cc1e6768c
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 14:32:49 2018 +0100

    third_party: Fix size type in cmocka
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 889d1daf8758841a8252916c4e85932ac6a6e6a6
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 16:25:30 2018 +0100

    ldb: Fix overflow checks
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit be709e8cde584dcc94d394ae3ae49e9342bb5d34
Author: Andreas Schneider <asn at samba.org>
Date:   Thu Mar 22 09:53:03 2018 +0100

    ldb: Add test for ldb_qsort()
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

commit 63e05322e2efec96edf6652a76fe93ae34b5c4c6
Author: Andreas Schneider <asn at samba.org>
Date:   Wed Mar 21 17:19:39 2018 +0100

    third_party: Update pam_wrapper to version 1.0.6
    
    This fixes compilation with -Wstrict-overflow=2.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Jeremy Allison <jra at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 buildtools/wafsamba/wafsamba.py                    |    5 +
 lib/ldb/common/qsort.c                             |   10 +-
 .../test_tldap.c => lib/ldb/tests/test_ldb_qsort.c |   44 +-
 lib/ldb/wscript                                    |    8 +-
 lib/replace/wscript                                |    3 +
 lib/util/samba_util.h                              |    2 +-
 lib/util/util_file.c                               |    4 +-
 source3/client/client.c                            |   23 +-
 source3/include/printing.h                         |    2 +-
 source3/modules/getdate.c                          | 1874 ++++++++++----------
 source3/modules/getdate.y                          |  243 ++-
 source3/modules/wscript_build                      |    5 +
 source3/printing/printing.c                        |   27 +-
 source3/rpc_server/spoolss/srv_spoolss_nt.c        |    2 +-
 source3/smbd/negprot.c                             |   13 +-
 source3/torture/wbc_async.c                        |    4 +-
 source4/client/client.c                            |    8 +-
 .../heimdal/lib/gssapi/mech/gss_set_cred_option.c  |    2 +-
 source4/heimdal/lib/krb5/addr_families.c           |   29 +-
 source4/lib/registry/tools/regshell.c              |    8 +-
 source4/torture/util_smb.c                         |   23 +-
 third_party/cmocka/cmocka.c                        |   24 +-
 third_party/pam_wrapper/pam_wrapper.c              |  126 +-
 third_party/pam_wrapper/wscript                    |    2 +-
 24 files changed, 1265 insertions(+), 1226 deletions(-)
 copy source3/lib/test_tldap.c => lib/ldb/tests/test_ldb_qsort.c (53%)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 1e331e5..12d5421 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -353,6 +353,7 @@ def SAMBA_BINARY(bld, binname, source,
                  modules=None,
                  ldflags=None,
                  cflags='',
+                 cflags_end=None,
                  autoproto=None,
                  use_hostcc=False,
                  use_global_deps=True,
@@ -410,6 +411,7 @@ def SAMBA_BINARY(bld, binname, source,
                         deps           = deps,
                         includes       = includes,
                         cflags         = pie_cflags,
+                        cflags_end     = cflags_end,
                         group          = subsystem_group,
                         autoproto      = autoproto,
                         subsystem_name = subsystem_name,
@@ -458,6 +460,7 @@ def SAMBA_MODULE(bld, modname, source,
                  autoproto=None,
                  autoproto_extra_source='',
                  cflags='',
+                 cflags_end=None,
                  internal_module=True,
                  local_include=True,
                  global_include=True,
@@ -488,6 +491,7 @@ def SAMBA_MODULE(bld, modname, source,
                     autoproto=autoproto,
                     autoproto_extra_source=autoproto_extra_source,
                     cflags=cflags,
+                    cflags_end=cflags_end,
                     local_include=local_include,
                     global_include=global_include,
                     allow_warnings=allow_warnings,
@@ -527,6 +531,7 @@ def SAMBA_MODULE(bld, modname, source,
                       deps=deps,
                       includes=includes,
                       cflags=cflags,
+                      cflags_end=cflags_end,
                       realname = realname,
                       autoproto = autoproto,
                       local_include=local_include,
diff --git a/lib/ldb/common/qsort.c b/lib/ldb/common/qsort.c
index 1a0b886..012aaf3 100644
--- a/lib/ldb/common/qsort.c
+++ b/lib/ldb/common/qsort.c
@@ -59,9 +59,8 @@ typedef struct
 #define CHAR_BIT 8
 #endif
 #define STACK_SIZE	(CHAR_BIT * sizeof(size_t))
-#define PUSH(low, high)	((void) ((top->lo = (low)), (top->hi = (high)), ++top))
-#define	POP(low, high)	((void) (--top, (low = top->lo), (high = top->hi)))
-#define	STACK_NOT_EMPTY	(stack < top)
+#define PUSH(low, high) ((void) ((stack[i].lo = (low)), (stack[i].hi = (high)), i++))
+#define POP(low, high)  ((void) (i--, (low = stack[i].lo), (high = stack[i].hi)))
 
 
 /* Order size using quicksort.  This implementation incorporates
@@ -104,11 +103,11 @@ void ldb_qsort (void *const pbase, size_t total_elems, size_t size,
       char *lo = base_ptr;
       char *hi = &lo[size * (total_elems - 1)];
       stack_node stack[STACK_SIZE];
-      stack_node *top = stack;
+      size_t i = 0;
 
       PUSH (NULL, NULL);
 
-      while (STACK_NOT_EMPTY)
+      do
         {
           char *left_ptr;
           char *right_ptr;
@@ -194,6 +193,7 @@ void ldb_qsort (void *const pbase, size_t total_elems, size_t size,
               hi = right_ptr;
             }
         }
+      while (i > 0 && i < STACK_SIZE);
     }
 
   /* Once the BASE_PTR array is partially sorted by quicksort the rest
diff --git a/source3/lib/test_tldap.c b/lib/ldb/tests/test_ldb_qsort.c
similarity index 53%
copy from source3/lib/test_tldap.c
copy to lib/ldb/tests/test_ldb_qsort.c
index a6c2f21..06e80d9 100644
--- a/source3/lib/test_tldap.c
+++ b/lib/ldb/tests/test_ldb_qsort.c
@@ -1,6 +1,5 @@
 /*
  * Unix SMB/CIFS implementation.
- * Test suite for ldap client
  *
  * Copyright (C) 2018      Andreas Schneider <asn at samba.org>
  *
@@ -23,40 +22,43 @@
 #include <setjmp.h>
 #include <cmocka.h>
 
-#include "source3/lib/tldap.c"
+#include <ldb.h>
 
-static void test_tldap_unescape_ldapv3(void **state)
+static int cmp_integer(int *a, int *b, void *opaque)
 {
-	const char *unescaped_dn = "(&(objectclass=group)(cn=Samba*))";
-	char dn[] = "\\28&\\28objectclass=group\\29\\28cn=Samba\\2a\\29\\29";
-	size_t dnlen = sizeof(dn);
-	bool ok;
+	if (a == NULL || b == NULL) {
+		return 0;
+	}
 
-	ok = tldap_unescape_inplace(dn, &dnlen);
-	assert_true(ok);
+	if (*a > *b) {
+		return 1;
+	}
 
-	assert_string_equal(dn, unescaped_dn);
+	if (*a < *b) {
+		return -1;
+	}
+
+	return 0;
 }
 
-static void test_tldap_unescape_ldapv2(void **state)
+static void test_ldb_qsort(void **state)
 {
-	const char *unescaped_dn = "(&(objectclass=group)(cn=Samba*))";
-	char dn[] = "\\(&\\(objectclass=group\\)\\(cn=Samba\\*\\)\\)";
-	size_t dnlen = sizeof(dn);
-	bool ok;
+	int a[6] = { 6, 3, 2, 7, 9, 4 };
 
-	ok = tldap_unescape_inplace(dn, &dnlen);
-	assert_true(ok);
+	ldb_qsort(a, 6, sizeof(int), NULL, (ldb_qsort_cmp_fn_t)cmp_integer);
 
-	assert_string_equal(dn, unescaped_dn);
+	assert_int_equal(a[0], 2);
+	assert_int_equal(a[1], 3);
+	assert_int_equal(a[2], 4);
+	assert_int_equal(a[3], 6);
+	assert_int_equal(a[4], 7);
+	assert_int_equal(a[5], 9);
 }
 
 int main(void) {
 	const struct CMUnitTest tests[] = {
-		cmocka_unit_test(test_tldap_unescape_ldapv3),
-		cmocka_unit_test(test_tldap_unescape_ldapv2)
+		cmocka_unit_test(test_ldb_qsort),
 	};
 
-	cmocka_set_message_output(CM_OUTPUT_SUBUNIT);
 	return cmocka_run_group_tests(tests, NULL, NULL);
 }
diff --git a/lib/ldb/wscript b/lib/ldb/wscript
index 1455f92..1c9573f 100644
--- a/lib/ldb/wscript
+++ b/lib/ldb/wscript
@@ -358,6 +358,11 @@ def build(bld):
                          deps='cmocka ldb',
                          install=False)
 
+        bld.SAMBA_BINARY('test_ldb_qsort',
+                         source='tests/test_ldb_qsort.c',
+                         deps='cmocka ldb',
+                         install=False)
+
 def test(ctx):
     '''run ldb testsuite'''
     import Utils, samba_utils, shutil
@@ -386,7 +391,8 @@ def test(ctx):
 
     cmocka_ret = 0
     for test_exe in ['ldb_tdb_mod_op_test',
-                     'ldb_msg_test']:
+                     'ldb_msg_test',
+                     'test_ldb_qsort']:
             cmd = os.path.join(Utils.g_module.blddir, test_exe)
             cmocka_ret = cmocka_ret or samba_utils.RUN_COMMAND(cmd)
 
diff --git a/lib/replace/wscript b/lib/replace/wscript
index 6639897..541573b 100644
--- a/lib/replace/wscript
+++ b/lib/replace/wscript
@@ -122,6 +122,9 @@ def configure(conf):
     if conf.CHECK_CFLAGS('-Wno-unused-function'):
         conf.define('HAVE_WNO_UNUSED_FUNCTION', '1')
 
+    if conf.CHECK_CFLAGS('-Wno-strict-overflow'):
+        conf.define('HAVE_WNO_STRICT_OVERFLOW', '1')
+
     # Check for process set name support
     conf.CHECK_CODE('''
                     #include <sys/prctl.h>
diff --git a/lib/util/samba_util.h b/lib/util/samba_util.h
index b782523..7b96a59 100644
--- a/lib/util/samba_util.h
+++ b/lib/util/samba_util.h
@@ -352,7 +352,7 @@ const char **str_list_make_v3_const(TALLOC_CTX *mem_ctx,
  */
 _PUBLIC_ char *afdgets(int fd, TALLOC_CTX *mem_ctx, size_t hint);
 
-char *fgets_slash(TALLOC_CTX *mem_ctx, char *s2, int maxlen, FILE *f);
+char *fgets_slash(TALLOC_CTX *mem_ctx, char *s2, size_t maxlen, FILE *f);
 
 /**
 load a file into memory from a fd.
diff --git a/lib/util/util_file.c b/lib/util/util_file.c
index 499e8c4..bf2f3e1 100644
--- a/lib/util/util_file.c
+++ b/lib/util/util_file.c
@@ -79,10 +79,10 @@ _PUBLIC_ char *afdgets(int fd, TALLOC_CTX *mem_ctx, size_t hint)
 	return data;
 }
 
-char *fgets_slash(TALLOC_CTX *mem_ctx, char *s2, int maxlen, FILE *f)
+char *fgets_slash(TALLOC_CTX *mem_ctx, char *s2, size_t maxlen, FILE *f)
 {
 	char *s = s2;
-	int len = 0;
+	size_t len = 0;
 	int c;
 	bool start_of_line = true;
 
diff --git a/source3/client/client.c b/source3/client/client.c
index 49d027a..23ed02d 100644
--- a/source3/client/client.c
+++ b/source3/client/client.c
@@ -186,16 +186,20 @@ static bool yesno(const char *p)
  number taken from the buffer. This may not equal the number written.
 ****************************************************************************/
 
-static int writefile(int f, char *b, int n)
+static ssize_t writefile(int f, char *b, size_t n)
 {
-	int i;
+	size_t i = 0;
+
+	if (n == 0) {
+		errno = EINVAL;
+		return -1;
+	}
 
 	if (!translation) {
 		return write(f,b,n);
 	}
 
-	i = 0;
-	while (i < n) {
+	do {
 		if (*b == '\r' && (i<(n-1)) && *(b+1) == '\n') {
 			b++;i++;
 		}
@@ -204,9 +208,9 @@ static int writefile(int f, char *b, int n)
 		}
 		b++;
 		i++;
-	}
+	} while (i < n);
 
-	return(i);
+	return (ssize_t)i;
 }
 
 /****************************************************************************
@@ -1092,7 +1096,10 @@ static int cmd_echo(void)
 static NTSTATUS writefile_sink(char *buf, size_t n, void *priv)
 {
 	int *pfd = (int *)priv;
-	if (writefile(*pfd, buf, n) == -1) {
+	ssize_t rc;
+
+	rc = writefile(*pfd, buf, n);
+	if (rc == -1) {
 		return map_nt_error_from_unix(errno);
 	}
 	return NT_STATUS_OK;
@@ -5954,7 +5961,7 @@ static char **completion_fn(const char *text, int start, int end)
 			return NULL;
 	} else {
 		char **matches;
-		int i, len, samelen = 0, count=1;
+		size_t i, len, samelen = 0, count=1;
 
 		matches = SMB_MALLOC_ARRAY(char *, MAX_COMPLETIONS);
 		if (!matches) {
diff --git a/source3/include/printing.h b/source3/include/printing.h
index 07b8678..6fb7301 100644
--- a/source3/include/printing.h
+++ b/source3/include/printing.h
@@ -63,7 +63,7 @@ enum {LPSTAT_OK, LPSTAT_STOPPED, LPSTAT_ERROR};
 
 typedef struct {
 	fstring message;
-	int qcount;
+	size_t qcount;
 	int status;
 }  print_status_struct;
 
diff --git a/source3/modules/getdate.c b/source3/modules/getdate.c
index 7a5d68e..ccc9b10 100644
--- a/source3/modules/getdate.c
+++ b/source3/modules/getdate.c
@@ -1,14 +1,13 @@
-/* A Bison parser, made by GNU Bison 2.3.  */
+/* A Bison parser, made by GNU Bison 3.0.4.  */
 
-/* Skeleton implementation for Bison's Yacc-like parsers in C
+/* Bison implementation for Yacc-like parsers in C
 
-   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
-   Free Software Foundation, Inc.
+   Copyright (C) 1984, 1989-1990, 2000-2015 Free Software Foundation, Inc.
 
-   This program is free software; you can redistribute it and/or modify
+   This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2, or (at your option)
-   any later version.
+   the Free Software Foundation, either version 3 of the License, or
+   (at your option) any later version.
 
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -16,9 +15,7 @@
    GNU General Public License for more details.
 
    You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 51 Franklin Street, Fifth Floor,
-   Boston, MA 02110-1301, USA.  */
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
 /* As a special exception, you may create a larger work that contains
    part or all of the Bison parser skeleton and distribute that work
@@ -47,7 +44,7 @@
 #define YYBISON 1
 
 /* Bison version.  */
-#define YYBISON_VERSION "2.3"
+#define YYBISON_VERSION "3.0.4"
 
 /* Skeleton name.  */
 #define YYSKELETON_NAME "yacc.c"
@@ -55,58 +52,17 @@
 /* Pure parsers.  */
 #define YYPURE 1
 
-/* Using locations.  */
-#define YYLSP_NEEDED 0
+/* Push parsers.  */
+#define YYPUSH 0
 
-
-
-/* Tokens.  */
-#ifndef YYTOKENTYPE
-# define YYTOKENTYPE
-   /* Put the tokens into the symbol table, so that GDB and other debuggers
-      know about them.  */
-   enum yytokentype {
-     tAGO = 258,
-     tDST = 259,
-     tDAY = 260,
-     tDAY_UNIT = 261,
-     tDAYZONE = 262,
-     tHOUR_UNIT = 263,
-     tLOCAL_ZONE = 264,
-     tMERIDIAN = 265,
-     tMINUTE_UNIT = 266,
-     tMONTH = 267,
-     tMONTH_UNIT = 268,
-     tSEC_UNIT = 269,
-     tYEAR_UNIT = 270,
-     tZONE = 271,
-     tSNUMBER = 272,
-     tUNUMBER = 273
-   };
-#endif
-/* Tokens.  */
-#define tAGO 258
-#define tDST 259
-#define tDAY 260
-#define tDAY_UNIT 261
-#define tDAYZONE 262
-#define tHOUR_UNIT 263
-#define tLOCAL_ZONE 264
-#define tMERIDIAN 265
-#define tMINUTE_UNIT 266
-#define tMONTH 267
-#define tMONTH_UNIT 268
-#define tSEC_UNIT 269
-#define tYEAR_UNIT 270
-#define tZONE 271
-#define tSNUMBER 272
-#define tUNUMBER 273
+/* Pull parsers.  */
+#define YYPULL 1
 
 
 
 
 /* Copy the first part of user declarations.  */
-#line 1 "getdate.y"
+#line 1 "source3/modules/getdate.y" /* yacc.c:339  */
 
 /* Parse a string into an internal time stamp.
    Copyright (C) 1999, 2000, 2002 Free Software Foundation, Inc.
@@ -214,7 +170,7 @@ typedef struct
 enum { MERam, MERpm, MER24 };
 
 /* Information passed to and from the parser.  */
-typedef struct
+struct parser_control
 {
   /* The input string remaining to be parsed. */
   const char *input;
@@ -260,18 +216,18 @@ typedef struct
 
   /* Table of local time zone abbrevations, terminated by a null entry.  */
   table local_time_zone_table[3];
-} parser_control;
-
-#define PC (* (parser_control *) parm)
-#define YYLEX_PARAM parm
-#define YYPARSE_PARAM parm
+};
 
 
+#line 223 "source3/modules/getdate.c" /* yacc.c:339  */
 
-/* Enabling traces.  */
-#ifndef YYDEBUG
-# define YYDEBUG 0
-#endif
+# ifndef YY_NULLPTR
+#  if defined __cplusplus && 201103L <= __cplusplus
+#   define YY_NULLPTR nullptr
+#  else
+#   define YY_NULLPTR 0
+#  endif
+# endif
 
 /* Enabling verbose error messages.  */
 #ifdef YYERROR_VERBOSE
@@ -281,39 +237,72 @@ typedef struct
 # define YYERROR_VERBOSE 0
 #endif
 
-/* Enabling the token table.  */
-#ifndef YYTOKEN_TABLE
-# define YYTOKEN_TABLE 0
+
+/* Debug traces.  */
+#ifndef YYDEBUG
+# define YYDEBUG 0
+#endif
+#if YYDEBUG
+extern int yydebug;
+#endif
+
+/* Token type.  */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+  enum yytokentype
+  {
+    tAGO = 258,
+    tDST = 259,
+    tDAY = 260,
+    tDAY_UNIT = 261,
+    tDAYZONE = 262,
+    tHOUR_UNIT = 263,
+    tLOCAL_ZONE = 264,
+    tMERIDIAN = 265,
+    tMINUTE_UNIT = 266,
+    tMONTH = 267,
+    tMONTH_UNIT = 268,
+    tSEC_UNIT = 269,
+    tYEAR_UNIT = 270,
+    tZONE = 271,
+    tSNUMBER = 272,
+    tUNUMBER = 273
+  };
 #endif
 
+/* Value type.  */
 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
-typedef union YYSTYPE
-#line 169 "getdate.y"
+
+union YYSTYPE
 {
+#line 168 "source3/modules/getdate.y" /* yacc.c:355  */
+


-- 
Samba Shared Repository



More information about the samba-cvs mailing list