The branch, master has been updated via 321dd78f fix typo in manual page via 6f10f125 When not using the builtin zlib, link it before linking libcrypto, as libcrypto depends on zlib. via 1a95869d Allow basic connectivity check via rrsync via c9fe6ca3 Introduce PTR_SUB via 990fa5c1 rrsync: fix wrong parameter name in manpage SYNOPSIS via 07069880 Fix warning about conflicting lseek/lseek64 prototypes via e55b190f Fix warning about missing bomb(..) prototype via 48d51a13 Fix __m128i_u / __m256i_u alignment from f654e476 Mention latest NEWS.
https://git.samba.org/?p=rsync.git;a=shortlog;h=master - Log ----------------------------------------------------------------- commit 321dd78f8cbdb5d01fa8628eb872e967f19e0883 Author: Frederic Grabowski <grabowski.frede...@gmail.com> Date: Fri May 10 10:49:56 2024 +0200 fix typo in manual page commit 6f10f125778c87a494509f5612fc43869791d469 Author: Romain Geissler <romain.geiss...@amadeus.com> Date: Sun Mar 10 22:41:43 2024 +0000 When not using the builtin zlib, link it before linking libcrypto, as libcrypto depends on zlib. This prevents "undefined symbol" errors which might arise from libcrypto.a if linking openssl statically. commit 1a95869dfcd966f3efef0aec07d1c787633ea638 Author: Colin Watson <cjwat...@debian.org> Date: Fri Mar 29 01:24:32 2024 +0000 Allow basic connectivity check via rrsync rsbackup (https://github.com/ewxrjk/rsbackup) uses "ssh <host> true" to check that the host in question is reachable. I like to configure my backed-up hosts to force the backup system to go via `rrsync`, but I always have to add a local tweak to allow `SSH_ORIGINAL_COMMAND=true` to work. I think this would be safe enough to include in rrsync. commit c9fe6ca30472b3ca22adb5550f6751334934e12f Author: Rose <83477269+ataridre...@users.noreply.github.com> Date: Wed May 3 09:52:18 2023 -0400 Introduce PTR_SUB This is more intuitive than adding a negative number. commit 990fa5c1e1abe3ef09a32115c4817f9a5fa3a797 Author: Samuel Henrique <samuel...@debian.org> Date: Fri Dec 29 15:23:27 2023 +0000 rrsync: fix wrong parameter name in manpage SYNOPSIS Replace ¨rw¨ with ¨ro¨. Reported on Debian by Adriano Rafael Gomes <adrian...@debian.org> commit 07069880a21bd43dbc3b240e87ba6699c8725baa Author: Holger Hoffstätte <hol...@applied-asynchrony.com> Date: Mon Sep 4 14:07:14 2023 +0200 Fix warning about conflicting lseek/lseek64 prototypes Clang rightfully complains about conflicting prototypes, as both lseek() variants are redefined: syscall.c:394:10: warning: a function declaration without a prototype is deprecated in all versions of C and is treated as a zero-parameter prototype in C2x, conflicting with a previous declaration [-Wdeprecated-non-prototype] off64_t lseek64(); ^ /usr/include/unistd.h:350:18: note: conflicting prototype is here extern __off64_t lseek64 (int __fd, __off64_t __offset, int __whence) ^ 1 warning generated. The point of the #ifdef is to build for the configured OFF_T; there is no reason to redefine lseek/lseek64, which should have been found via configure. Signed-off-by: Holger Hoffstätte <hol...@applied-asynchrony.com> commit e55b190f4a7c0f9d942bc50be00ab176e3c4dc90 Author: Holger Hoffstätte <hol...@applied-asynchrony.com> Date: Mon Sep 4 14:05:21 2023 +0200 Fix warning about missing bomb(..) prototype Clang rightfully complains about invoking bomb(..) without a proper prototype: lib/pool_alloc.c:171:16: warning: passing arguments to a function without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype] (*pool->bomb)(bomb_msg, __FILE__, __LINE__); ^ 1 warning generated. Signed-off-by: Holger Hoffstätte <hol...@applied-asynchrony.com> commit 48d51a1370f0facb54fa80864077fd7d769cb03d Author: Holger Hoffstätte <hol...@applied-asynchrony.com> Date: Mon Sep 4 14:00:20 2023 +0200 Fix __m128i_u / __m256i_u alignment Building with clang-16 complains with: ./simd-checksum-x86_64.cpp:204:25: warning: passing 1-byte aligned argument to 16-byte aligned parameter 1 of '_mm_store_si128' may result in an unaligned pointer access [-Walign-mismatch] Signed-off-by: Holger Hoffstätte <hol...@applied-asynchrony.com> ----------------------------------------------------------------------- Summary of changes: configure.ac | 40 ++++++++++++++++++++-------------------- lib/pool_alloc.c | 9 +++++---- rsync.1.md | 2 +- simd-checksum-x86_64.cpp | 4 ++-- support/rrsync | 4 ++++ support/rrsync.1.md | 2 +- syscall.c | 5 ----- 7 files changed, 33 insertions(+), 33 deletions(-) Changeset truncated at 500 lines: diff --git a/configure.ac b/configure.ac index 390c5961..d2bcb471 100644 --- a/configure.ac +++ b/configure.ac @@ -424,6 +424,26 @@ case $host_os in * ) AC_MSG_RESULT(no);; esac +# We default to using our zlib unless --with-included-zlib=no is given. +if test x"$with_included_zlib" != x"no"; then + with_included_zlib=yes +elif test x"$ac_cv_header_zlib_h" != x"yes"; then + with_included_zlib=yes +fi +if test x"$with_included_zlib" != x"yes"; then + AC_CHECK_LIB(z, deflateParams, , [with_included_zlib=yes]) +fi + +AC_MSG_CHECKING([whether to use included zlib]) +if test x"$with_included_zlib" = x"yes"; then + AC_MSG_RESULT($srcdir/zlib) + BUILD_ZLIB='$(zlib_OBJS)' + CFLAGS="-I$srcdir/zlib $CFLAGS" +else + AC_DEFINE(EXTERNAL_ZLIB, 1, [Define to 1 if using external zlib]) + AC_MSG_RESULT(no) +fi + AC_MSG_CHECKING([whether to enable use of openssl crypto library]) AC_ARG_ENABLE([openssl], AS_HELP_STRING([--disable-openssl],[disable to omit openssl crypto library])) @@ -1096,26 +1116,6 @@ else AC_MSG_RESULT(no) fi -# We default to using our zlib unless --with-included-zlib=no is given. -if test x"$with_included_zlib" != x"no"; then - with_included_zlib=yes -elif test x"$ac_cv_header_zlib_h" != x"yes"; then - with_included_zlib=yes -fi -if test x"$with_included_zlib" != x"yes"; then - AC_CHECK_LIB(z, deflateParams, , [with_included_zlib=yes]) -fi - -AC_MSG_CHECKING([whether to use included zlib]) -if test x"$with_included_zlib" = x"yes"; then - AC_MSG_RESULT($srcdir/zlib) - BUILD_ZLIB='$(zlib_OBJS)' - CFLAGS="-I$srcdir/zlib $CFLAGS" -else - AC_DEFINE(EXTERNAL_ZLIB, 1, [Define to 1 if using external zlib]) - AC_MSG_RESULT(no) -fi - AC_CACHE_CHECK([for unsigned char],rsync_cv_SIGNED_CHAR_OK,[ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[signed char *s = (signed char *)""]])],[rsync_cv_SIGNED_CHAR_OK=yes],[rsync_cv_SIGNED_CHAR_OK=no])]) if test x"$rsync_cv_SIGNED_CHAR_OK" = x"yes"; then diff --git a/lib/pool_alloc.c b/lib/pool_alloc.c index a1a7245f..b49e3a7b 100644 --- a/lib/pool_alloc.c +++ b/lib/pool_alloc.c @@ -9,7 +9,7 @@ struct alloc_pool size_t size; /* extent size */ size_t quantum; /* allocation quantum */ struct pool_extent *extents; /* top extent is "live" */ - void (*bomb)(); /* called if malloc fails */ + void (*bomb)(const char*, const char*, int); /* called if malloc fails */ int flags; /* statistical data */ @@ -42,6 +42,7 @@ struct align_test { /* Temporarily cast a void* var into a char* var when adding an offset (to * keep some compilers from complaining about the pointer arithmetic). */ #define PTR_ADD(b,o) ( (void*) ((char*)(b) + (o)) ) +#define PTR_SUB(b,o) ( (void*) ((char*)(b) - (o)) ) alloc_pool_t pool_create(size_t size, size_t quantum, void (*bomb)(const char*, const char*, int), int flags) @@ -100,7 +101,7 @@ pool_destroy(alloc_pool_t p) for (cur = pool->extents; cur; cur = next) { next = cur->next; if (pool->flags & POOL_PREPEND) - free(PTR_ADD(cur->start, -sizeof (struct pool_extent))); + free(PTR_SUB(cur->start, sizeof (struct pool_extent))); else { free(cur->start); free(cur); @@ -235,7 +236,7 @@ pool_free(alloc_pool_t p, size_t len, void *addr) if (cur->free + cur->bound >= pool->size) { prev->next = cur->next; if (pool->flags & POOL_PREPEND) - free(PTR_ADD(cur->start, -sizeof (struct pool_extent))); + free(PTR_SUB(cur->start, sizeof (struct pool_extent))); else { free(cur->start); free(cur); @@ -292,7 +293,7 @@ pool_free_old(alloc_pool_t p, void *addr) while ((cur = next) != NULL) { next = cur->next; if (pool->flags & POOL_PREPEND) - free(PTR_ADD(cur->start, -sizeof (struct pool_extent))); + free(PTR_SUB(cur->start, sizeof (struct pool_extent))); else { free(cur->start); free(cur); diff --git a/rsync.1.md b/rsync.1.md index 4407a013..7e40e361 100644 --- a/rsync.1.md +++ b/rsync.1.md @@ -3995,7 +3995,7 @@ option (though the 2 commands behave differently if deletions are enabled): > rsync -aiR x/y/file.txt host:/tmp/ The following command does not need an include of the "x" directory because it -is not a part of the transfer (note the traililng slash). Running this command +is not a part of the transfer (note the trailing slash). Running this command would copy just "`/tmp/x/file.txt`" because the "y" and "z" dirs get excluded: > rsync -ai -f'+ file.txt' -f'- *' x/ host:/tmp/x/ diff --git a/simd-checksum-x86_64.cpp b/simd-checksum-x86_64.cpp index 33f26e92..d649091e 100644 --- a/simd-checksum-x86_64.cpp +++ b/simd-checksum-x86_64.cpp @@ -68,8 +68,8 @@ #endif // Missing from the headers on gcc 6 and older, clang 8 and older -typedef long long __m128i_u __attribute__((__vector_size__(16), __may_alias__, __aligned__(1))); -typedef long long __m256i_u __attribute__((__vector_size__(32), __may_alias__, __aligned__(1))); +typedef long long __m128i_u __attribute__((__vector_size__(16), __may_alias__, __aligned__(16))); +typedef long long __m256i_u __attribute__((__vector_size__(32), __may_alias__, __aligned__(16))); /* Compatibility macros to let our SSSE3 algorithm run with only SSE2. These used to be neat individual functions with target attributes switching between SSE2 and SSSE3 implementations diff --git a/support/rrsync b/support/rrsync index 4b4b87c5..e8b0cc0d 100755 --- a/support/rrsync +++ b/support/rrsync @@ -156,6 +156,10 @@ def main(): command = os.environ.get('SSH_ORIGINAL_COMMAND', None) if not command: die("Not invoked via sshd") + if command == 'true': + # Allow checking connectivity with "ssh <host> true". (For example, + # rsbackup uses this.) + sys.exit(0) command = command.split(' ', 2) if command[0:1] != ['rsync']: die("SSH_ORIGINAL_COMMAND does not run rsync") diff --git a/support/rrsync.1.md b/support/rrsync.1.md index 5f33930e..09b2f282 100644 --- a/support/rrsync.1.md +++ b/support/rrsync.1.md @@ -5,7 +5,7 @@ rrsync - a script to setup restricted rsync users via ssh logins ## SYNOPSIS ``` -rrsync [-ro|-rw] [-munge] [-no-del] [-no-lock] [-no-overwrite] DIR +rrsync [-ro|-wo] [-munge] [-no-del] [-no-lock] [-no-overwrite] DIR ``` The single non-option argument specifies the restricted _DIR_ to use. It can be diff --git a/syscall.c b/syscall.c index d92074aa..b4b0f1f1 100644 --- a/syscall.c +++ b/syscall.c @@ -388,11 +388,6 @@ int do_fstat(int fd, STRUCT_STAT *st) OFF_T do_lseek(int fd, OFF_T offset, int whence) { #ifdef HAVE_LSEEK64 -#if !SIZEOF_OFF64_T - OFF_T lseek64(); -#else - off64_t lseek64(); -#endif return lseek64(fd, offset, whence); #else return lseek(fd, offset, whence); -- The rsync repository.
_______________________________________________ rsync-cvs mailing list rsync-cvs@lists.samba.org https://lists.samba.org/mailman/listinfo/rsync-cvs