import rsync-3.1.3-12.el8
This commit is contained in:
parent
3e1ef80c12
commit
5700cceaf3
44
SOURCES/rsync-3.1.3-append-check.patch
Normal file
44
SOURCES/rsync-3.1.3-append-check.patch
Normal file
@ -0,0 +1,44 @@
|
||||
commit bd17c2a4e237ca1f38544db65053ecfea6054009
|
||||
Author: Tomas Korbar <tkorbar@redhat.com>
|
||||
Date: Thu Sep 24 13:17:45 2020 +0200
|
||||
|
||||
Skip files for transfer that has been truncated during negotiation
|
||||
|
||||
diff --git a/rsync.1 b/rsync.1
|
||||
index 6cabd44..855dd47 100644
|
||||
--- a/rsync.1
|
||||
+++ b/rsync.1
|
||||
@@ -1004,8 +1004,10 @@ This causes rsync to update a file by appending data onto
|
||||
the end of the file, which presumes that the data that already exists on
|
||||
the receiving side is identical with the start of the file on the sending
|
||||
side. If a file needs to be transferred and its size on the receiver is
|
||||
-the same or longer than the size on the sender, the file is skipped. This
|
||||
-does not interfere with the updating of a file\(cq\&s non\-content attributes
|
||||
+the same or longer than the size on the sender, the file is skipped. It
|
||||
+also skips any files whose size on the sending side gets shorter during
|
||||
+the send negotiations (rsync warns about a "diminished" file when this
|
||||
+happens). This does not interfere with the updating of a file\(cq\&s non\-content attributes
|
||||
(e.g. permissions, ownership, etc.) when the file does not need to be
|
||||
transferred, nor does it affect the updating of any non\-regular files.
|
||||
Implies \fB\-\-inplace\fP.
|
||||
diff --git a/sender.c b/sender.c
|
||||
index 1cc28a1..e22eadd 100644
|
||||
--- a/sender.c
|
||||
+++ b/sender.c
|
||||
@@ -379,6 +379,16 @@ void send_files(int f_in, int f_out)
|
||||
}
|
||||
}
|
||||
|
||||
+ if (append_mode > 0 && st.st_size < F_LENGTH(file)) {
|
||||
+ rprintf(FWARNING, "skipped diminished file: %s\n",
|
||||
+ full_fname(fname));
|
||||
+ free_sums(s);
|
||||
+ close(fd);
|
||||
+ if (protocol_version >= 30)
|
||||
+ send_msg_int(MSG_NO_SEND, ndx);
|
||||
+ continue;
|
||||
+ }
|
||||
+
|
||||
if (st.st_size) {
|
||||
int32 read_size = MAX(s->blength * 3, MAX_MAP_SIZE);
|
||||
mbuf = map_file(fd, st.st_size, read_size, s->blength);
|
49
SOURCES/rsync-3.1.3-ignore-missing.patch
Normal file
49
SOURCES/rsync-3.1.3-ignore-missing.patch
Normal file
@ -0,0 +1,49 @@
|
||||
commit af6118d98b3482cbcfc223bf2a0777bc19eccb02
|
||||
Author: Wayne Davison <wayne@opencoder.net>
|
||||
Date: Sun Apr 26 18:02:17 2020 -0700
|
||||
|
||||
Allow a missing parent dir when --delete-missing-args was specified.
|
||||
|
||||
diff --git a/generator.c b/generator.c
|
||||
index 3c50f63f..b90c7ccd 100644
|
||||
--- a/generator.c
|
||||
+++ b/generator.c
|
||||
@@ -1277,10 +1277,16 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx,
|
||||
&& (*dn != '.' || dn[1]) /* Avoid an issue with --relative and the "." dir. */
|
||||
&& (!prior_dir_file || strcmp(dn, f_name(prior_dir_file, NULL)) != 0)
|
||||
&& flist_find_name(cur_flist, dn, 1) < 0) {
|
||||
- rprintf(FERROR,
|
||||
- "ABORTING due to invalid path from sender: %s/%s\n",
|
||||
- dn, file->basename);
|
||||
- exit_cleanup(RERR_PROTOCOL);
|
||||
+ /* The --delete-missing-args option can actually put invalid entries into
|
||||
+ * the file list, so if that option was specified, we'll just complain about
|
||||
+ * it and allow it. */
|
||||
+ if (missing_args == 2 && file->mode == 0)
|
||||
+ rprintf(FERROR, "WARNING: parent dir is absent in the file list: %s\n", dn);
|
||||
+ else {
|
||||
+ rprintf(FERROR, "ABORTING due to invalid path from sender: %s/%s\n",
|
||||
+ dn, file->basename);
|
||||
+ exit_cleanup(RERR_PROTOCOL);
|
||||
+ }
|
||||
}
|
||||
if (relative_paths && !implied_dirs
|
||||
&& do_stat(dn, &sx.st) < 0) {
|
||||
@@ -1383,7 +1389,7 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx,
|
||||
added_perms = 0;
|
||||
if (is_dir < 0) {
|
||||
if (!(preserve_times & PRESERVE_DIR_TIMES))
|
||||
- return;
|
||||
+ goto cleanup;
|
||||
/* In inc_recurse mode we want to make sure any missing
|
||||
* directories get created while we're still processing
|
||||
* the parent dir (which allows us to touch the parent
|
||||
@@ -1525,7 +1531,7 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx,
|
||||
"ignoring unsafe symlink \"%s\" -> \"%s\"\n",
|
||||
fname, sl);
|
||||
}
|
||||
- return;
|
||||
+ goto cleanup;
|
||||
}
|
||||
if (statret == 0) {
|
||||
char lnk[MAXPATHLEN];
|
37
SOURCES/rsync-3.1.3-skip-compress.patch
Normal file
37
SOURCES/rsync-3.1.3-skip-compress.patch
Normal file
@ -0,0 +1,37 @@
|
||||
diff --git a/loadparm.c b/loadparm.c
|
||||
index 029f358f..534e7b63 100644
|
||||
--- a/loadparm.c
|
||||
+++ b/loadparm.c
|
||||
@@ -449,7 +449,7 @@ static struct parm_struct parm_table[] =
|
||||
};
|
||||
|
||||
/* Initialise the Default all_vars structure. */
|
||||
-static void reset_all_vars(void)
|
||||
+void reset_daemon_vars(void)
|
||||
{
|
||||
memcpy(&Vars, &Defaults, sizeof Vars);
|
||||
}
|
||||
@@ -872,7 +872,7 @@ int lp_load(char *pszFname, int globals_only)
|
||||
{
|
||||
bInGlobalSection = True;
|
||||
|
||||
- reset_all_vars();
|
||||
+ reset_daemon_vars();
|
||||
|
||||
/* We get sections first, so have to start 'behind' to make up. */
|
||||
iSectionIndex = -1;
|
||||
diff --git a/main.c b/main.c
|
||||
index 1328c504..9af9e5d3 100644
|
||||
--- a/main.c
|
||||
+++ b/main.c
|
||||
@@ -1681,6 +1681,10 @@ int main(int argc,char *argv[])
|
||||
|
||||
memset(&stats, 0, sizeof(stats));
|
||||
|
||||
+ /* Even a non-daemon runs needs the default config values to be set, e.g.
|
||||
+ * lp_dont_compress() is queried when no --skip-compress option is set. */
|
||||
+ reset_daemon_vars();
|
||||
+
|
||||
if (argc < 2) {
|
||||
usage(FERROR);
|
||||
exit_cleanup(RERR_SYNTAX);
|
@ -9,7 +9,7 @@
|
||||
Summary: A program for synchronizing files over a network
|
||||
Name: rsync
|
||||
Version: 3.1.3
|
||||
Release: 9%{?dist}
|
||||
Release: 12%{?dist}
|
||||
Group: Applications/Internet
|
||||
URL: http://rsync.samba.org/
|
||||
|
||||
@ -32,6 +32,9 @@ Patch1: rsync-3.0.6-iconv-logging.patch
|
||||
Patch2: rsync-3.1.3-covscan.patch
|
||||
Patch3: rsync-3.1.2-remove-symlinks.patch
|
||||
Patch4: rsync-3.1.2-vvv-hang.patch
|
||||
Patch5: rsync-3.1.3-ignore-missing.patch
|
||||
Patch6: rsync-3.1.3-append-check.patch
|
||||
Patch7: rsync-3.1.3-skip-compress.patch
|
||||
|
||||
%description
|
||||
Rsync uses a reliable algorithm to bring remote and host files into
|
||||
@ -74,9 +77,11 @@ patch -p1 -i patches/copy-devices.diff
|
||||
%patch2 -p1 -b .covscan
|
||||
%patch3 -p1 -b .symlinks
|
||||
%patch4 -p1 -b .vvv
|
||||
%patch5 -p1 -b .missing
|
||||
%patch6 -p1 -b .append
|
||||
%patch7 -p1 -b .skip-compress
|
||||
|
||||
%build
|
||||
|
||||
%configure
|
||||
# --with-included-zlib=no temporary disabled because of #1043965
|
||||
|
||||
@ -121,10 +126,19 @@ chmod -x support/*
|
||||
%systemd_postun_with_restart rsyncd.service
|
||||
|
||||
%changelog
|
||||
* Mon Aug 24 2020 Michal Ruprich <michalruprich@gmail.com> - 3.1.3-9
|
||||
* Fri Dec 18 2020 Michal Ruprich <mruprich@redhat.com> - 3.1.3-12
|
||||
- Resolves: #1816528 - Defaults for --skip-compress are not working, everything is being compressed
|
||||
|
||||
* Thu Nov 05 2020 Tomas Korbar <tkorbar@redhat.com> - 3.1.3-11
|
||||
- Resolves: #1855981 - rsync segfaults in --append mode
|
||||
|
||||
* Thu Nov 05 2020 Tomas Korbar <tkorbar@redhat.com> - 3.1.3-10
|
||||
- Resolves: #1727093 - rsync: "ABORTING due to invalid path from sender"
|
||||
|
||||
* Mon Aug 24 2020 Michal Ruprich <mruprich@redhat.com> - 3.1.3-9
|
||||
- Resolves: #1667436 - rsyncd.service fails to start at boot if address is configured
|
||||
|
||||
* Wed Jun 10 2020 Michal Ruprich <michalruprich@gmail.com> - 3.1.3-8
|
||||
* Wed Jun 10 2020 Michal Ruprich <mruprich@redhat.com> - 3.1.3-8
|
||||
- Resolves: #1775561 - rsync 3.1.2 hangs when run with -vvv to sync a large repository
|
||||
|
||||
* Tue Oct 29 2019 Michal Ruprich <mruprich@redhat.com> - 3.1.3-7
|
||||
|
Loading…
Reference in New Issue
Block a user