[SCM] The rsync repository. - branch master updated

Rsync CVS commit messages rsync-cvs at lists.samba.org
Fri Aug 19 00:34:51 UTC 2022


The branch, master has been updated
       via  9a3449a3 Stop enabling -pedantic-errors.
       via  3258534e Change name_num_obj struct to use a name_num_item pointer.
       via  b94bba40 Fix typos on manpage (#358)
       via  a182507b Fix issue when the files-from list isn't nl terminated.
       via  2895b65f Another mkgitver tweak & mention it in NEWS.
      from  def595c5 Remove useless comment.

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


- Log -----------------------------------------------------------------
commit 9a3449a3980421f84ac55498ba565bc112b20d6c
Author: Wayne Davison <wayne at opencoder.net>
Date:   Thu Aug 18 17:33:54 2022 -0700

    Stop enabling -pedantic-errors.

commit 3258534e994549e07bc65e2ddf11636078f4a8d2
Author: Wayne Davison <wayne at opencoder.net>
Date:   Thu Aug 18 17:33:11 2022 -0700

    Change name_num_obj struct to use a name_num_item pointer.

commit b94bba40361acf1b7b9da41b02aa3d6b6e47943d
Author: Samuel Henrique <samueloph at debian.org>
Date:   Thu Aug 18 05:50:43 2022 +0100

    Fix typos on manpage (#358)

commit a182507bef2d0cd92052b3c5ebaf1d98278e0dad
Author: Wayne Davison <wayne at opencoder.net>
Date:   Wed Aug 17 16:57:39 2022 -0700

    Fix issue when the files-from list isn't nl terminated.

commit 2895b65f53f3a5b54026a1761d7bb4e779bebf3b
Author: Wayne Davison <wayne at opencoder.net>
Date:   Tue Aug 16 08:38:58 2022 -0700

    Another mkgitver tweak & mention it in NEWS.

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

Summary of changes:
 NEWS.md      |  9 ++++++++-
 checksum.c   | 24 +++++++++++++-----------
 compat.c     | 20 +++++++++++---------
 configure.ac | 15 ---------------
 exclude.c    |  2 ++
 mkgitver     | 13 +++++--------
 rsync.1.md   |  4 ++--
 rsync.h      |  2 +-
 8 files changed, 42 insertions(+), 47 deletions(-)


Changeset truncated at 500 lines:

diff --git a/NEWS.md b/NEWS.md
index 8b9624a2..2196c33c 100644
--- a/NEWS.md
+++ b/NEWS.md
@@ -8,7 +8,14 @@
   args.
 
 - Fixed a bug in the internal MD4 checksum code that could cause the digest
-  to be incorrect part of the time (the openssl version was/is fine).
+  to be sporadically incorrect (the openssl version was/is fine).
+
+### PACKAGING RELATED:
+
+- The mkgitver script now makes sure that a `.git` dir/file is in the top-level
+  source dir before calling `git describe`. It also runs a basic check on the
+  version value. This should avoid using an unrelated git description for
+  rsync's version.
 
 ------------------------------------------------------------------------------
 
diff --git a/checksum.c b/checksum.c
index 758b489d..7eb50f17 100644
--- a/checksum.c
+++ b/checksum.c
@@ -42,21 +42,23 @@ extern int protocol_version;
 extern int proper_seed_order;
 extern const char *checksum_choice;
 
-struct name_num_obj valid_checksums = {
-	"checksum", NULL, NULL, 0, 0, {
+struct name_num_item valid_checksums_items[] = {
 #ifdef SUPPORT_XXH3
-		{ CSUM_XXH3_128, "xxh128", NULL },
-		{ CSUM_XXH3_64, "xxh3", NULL },
+	{ CSUM_XXH3_128, "xxh128", NULL },
+	{ CSUM_XXH3_64, "xxh3", NULL },
 #endif
 #ifdef SUPPORT_XXHASH
-		{ CSUM_XXH64, "xxh64", NULL },
-		{ CSUM_XXH64, "xxhash", NULL },
+	{ CSUM_XXH64, "xxh64", NULL },
+	{ CSUM_XXH64, "xxhash", NULL },
 #endif
-		{ CSUM_MD5, "md5", NULL },
-		{ CSUM_MD4, "md4", NULL },
-		{ CSUM_NONE, "none", NULL },
-		{ 0, NULL, NULL }
-	}
+	{ CSUM_MD5, "md5", NULL },
+	{ CSUM_MD4, "md4", NULL },
+	{ CSUM_NONE, "none", NULL },
+	{ 0, NULL, NULL }
+};
+
+struct name_num_obj valid_checksums = {
+	"checksum", NULL, NULL, 0, 0, valid_checksums_items
 };
 
 int xfersum_type = 0; /* used for the file transfer checksums */
diff --git a/compat.c b/compat.c
index b46eb199..622910eb 100644
--- a/compat.c
+++ b/compat.c
@@ -91,19 +91,21 @@ int filesfrom_convert = 0;
 
 #define MAX_NSTR_STRLEN 256
 
-struct name_num_obj valid_compressions = {
-	"compress", NULL, NULL, 0, 0, {
+struct name_num_item valid_compressions_items[] = {
 #ifdef SUPPORT_ZSTD
-		{ CPRES_ZSTD, "zstd", NULL },
+	{ CPRES_ZSTD, "zstd", NULL },
 #endif
 #ifdef SUPPORT_LZ4
-		{ CPRES_LZ4, "lz4", NULL },
+	{ CPRES_LZ4, "lz4", NULL },
 #endif
-		{ CPRES_ZLIBX, "zlibx", NULL },
-		{ CPRES_ZLIB, "zlib", NULL },
-		{ CPRES_NONE, "none", NULL },
-		{ 0, NULL, NULL }
-	}
+	{ CPRES_ZLIBX, "zlibx", NULL },
+	{ CPRES_ZLIB, "zlib", NULL },
+	{ CPRES_NONE, "none", NULL },
+	{ 0, NULL, NULL }
+};
+
+struct name_num_obj valid_compressions = {
+	"compress", NULL, NULL, 0, 0, valid_compressions_items
 };
 
 #define CF_INC_RECURSE	 (1<<0)
diff --git a/configure.ac b/configure.ac
index d185b2d3..cfc0117f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1071,21 +1071,6 @@ elif test x"$ac_cv_header_popt_h" != x"yes"; then
     with_included_popt=yes
 fi
 
-if test x"$GCC" = x"yes"; then
-    if test x"$with_included_popt" != x"yes"; then
-	# Turn pedantic warnings into errors to ensure an array-init overflow is an error.
-	CFLAGS="$CFLAGS -pedantic-errors"
-    else
-	# Our internal popt code cannot be compiled with pedantic warnings as errors, so try to
-	# turn off pedantic warnings (which will not lose the error for array-init overflow).
-	# Older gcc versions don't understand -Wno-pedantic, so check if --help=warnings lists
-	# -Wpedantic and use that as a flag.
-	case `$CC --help=warnings 2>/dev/null | grep Wpedantic` in
-	    *-Wpedantic*) CFLAGS="$CFLAGS -pedantic-errors -Wno-pedantic" ;;
-	esac
-    fi
-fi
-
 AC_MSG_CHECKING([whether to use included libpopt])
 if test x"$with_included_popt" = x"yes"; then
     AC_MSG_RESULT($srcdir/popt)
diff --git a/exclude.c b/exclude.c
index 730d04ef..777874aa 100644
--- a/exclude.c
+++ b/exclude.c
@@ -361,6 +361,8 @@ void implied_include_partial_string(const char *s_start, const char *s_end)
 void free_implied_include_partial_string()
 {
 	if (partial_string_buf) {
+		if (partial_string_len)
+			add_implied_include("", 0);
 		free(partial_string_buf);
 		partial_string_buf = NULL;
 	}
diff --git a/mkgitver b/mkgitver
index 43156c65..fe8a3d15 100755
--- a/mkgitver
+++ b/mkgitver
@@ -2,16 +2,13 @@
 
 srcdir=`dirname $0`
 
-if [ -e "$srcdir/.git" ]; then
-    gitver=`git describe --abbrev=8 2>/dev/null`
-fi
-
 if [ ! -f git-version.h ]; then
     touch git-version.h
 fi
 
-case "$gitver" in
-    *.*)
+if [ -e "$srcdir/.git" ]; then
+    gitver=`git describe --abbrev=8 2>/dev/null | sed -n '/^v3\.[0-9][0-9]*\.[0-9][0-9]*\(-\|$\)/p'`
+    if [ -n "$gitver" ]; then
 	echo "#define RSYNC_GITVER \"$gitver\"" >git-version.h.new
 	if ! diff git-version.h.new git-version.h >/dev/null; then
 	    echo "Updating git-version.h"
@@ -19,5 +16,5 @@ case "$gitver" in
 	else
 	    rm git-version.h.new
 	fi
-	;;
-esac
+    fi
+fi
diff --git a/rsync.1.md b/rsync.1.md
index f29495f2..1a3e8607 100644
--- a/rsync.1.md
+++ b/rsync.1.md
@@ -1904,13 +1904,13 @@ expand it.
 
     By default, an exclude or include has both a server-side effect (to "hide"
     and "show" files when building the server's file list) and a receiver-side
-    effect (to "protect" and "risk" files when deletions are occuring).  Any
+    effect (to "protect" and "risk" files when deletions are occurring).  Any
     rule that has no modifier to specify what sides it is executed on will be
     instead treated as if it were a server-side rule only, avoiding any
     "protect" effects of the rules.
 
     A rule can still apply to both sides even with this option specified if the
-    rule is given both the sender & receiver modifer letters (e.g., `-f'-sr
+    rule is given both the sender & receiver modifier letters (e.g., `-f'-sr
     foo'`).  Receiver-side protect/risk rules can also be explicitly specified
     to limit the deletions.  This saves you from having to edit a bunch of
     `-f'- foo'` rules into `-f'-s foo'` (aka `-f'H foo'`) rules (not to mention
diff --git a/rsync.h b/rsync.h
index 1cc037c5..e29c37c3 100644
--- a/rsync.h
+++ b/rsync.h
@@ -1172,7 +1172,7 @@ struct name_num_obj {
 	uchar *saw;
 	int saw_len;
 	int negotiated_num;
-	struct name_num_item list[10]; /* we'll get a compile error/warning if this is ever too small */
+	struct name_num_item *list;
 };
 
 #ifdef EXTERNAL_ZLIB


-- 
The rsync repository.



More information about the rsync-cvs mailing list