I've just uploaded an NMU fixing:

#872057: flexbackup stores multiple copies of files in backup archive
#916602: flexbackup: calls find with invalid option ordering

The debdiff is attached.

Since the package is Orphaned I went for the direct upload queue rather
than a delayed one.

Ian.
diff -u flexbackup-1.2.1/debian/changelog flexbackup-1.2.1/debian/changelog
--- flexbackup-1.2.1/debian/changelog
+++ flexbackup-1.2.1/debian/changelog
@@ -1,3 +1,14 @@
+flexbackup (1.2.1-6.4) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Pass `--no-recursion` earlier in the comand-line when calling out to `tar`
+    since the argument now only applies to arguments which follow it. Thanks to
+    Florian Schmidt for diagnosing and providing a patch. (Closes: #872057)
+  * Pass `-xdev` earlier in the command line when calling out to `find`. This
+    stops `find` from issuing a warning. (Closes: #916602).
+
+ -- Ian Campbell <i...@debian.org>  Sun, 16 Dec 2018 14:05:52 +0000
+
 flexbackup (1.2.1-6.3) unstable; urgency=medium
 
   * Non-maintainer upload.
diff -u flexbackup-1.2.1/debian/patches/00list flexbackup-1.2.1/debian/patches/00list
--- flexbackup-1.2.1/debian/patches/00list
+++ flexbackup-1.2.1/debian/patches/00list
@@ -11,0 +12,2 @@
+71_duplicate_files_in_tar.dpatch
+72_xdev_is_non_positional.dpatch
only in patch2:
unchanged:
--- flexbackup-1.2.1.orig/debian/patches/71_duplicate_files_in_tar.dpatch
+++ flexbackup-1.2.1/debian/patches/71_duplicate_files_in_tar.dpatch
@@ -0,0 +1,28 @@
+#!/bin/sh /usr/share/dpatch/dpatch-run
+## 71_duplicate_files_in_tar.dpatch by Florian Schmidt <deb...@fajs.de>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Bug #872057 patch by Florian Schmidt <deb...@fajs.de>
+## DP:
+## DP: This is due to a change in the behavior of tar's --no-recursion option.
+## DP: In either 1.28 or 1.29, it was changed to only apply to all options
+## DP: *following* it. Since the flexbackup command line has --files-from
+## DP: before --no-recursion, the --no-recursion is effectively ignored. (See
+## DP: also bug #829738)
+
+@DPATCH@
+--- a/flexbackup	2018-03-07 21:51:57.950379925 +0100
++++ b/flexbackup	2018-03-07 21:52:17.418333887 +0100
+@@ -1405,11 +1405,11 @@
+     $cmd .= "| ";
+ 
+     $cmd .= "$::path{tar} --create ";
++    $cmd .= "--no-recursion ";
+     $cmd .= "--null ";
+     $cmd .= "--files-from=- ";
+     $cmd .= "--ignore-failed-read ";
+     $cmd .= "--same-permissions ";
+-    $cmd .= "--no-recursion ";
+     $cmd .= "--totals ";
+     if ($cfg::label ne 'false') {
+ 	if (length($title) > $::tar_max_label) {
only in patch2:
unchanged:
--- flexbackup-1.2.1.orig/debian/patches/72_xdev_is_non_positional.dpatch
+++ flexbackup-1.2.1/debian/patches/72_xdev_is_non_positional.dpatch
@@ -0,0 +1,57 @@
+#!/bin/sh /usr/share/dpatch/dpatch-run
+## 72_xdev_is_non_positional.dpatch by Ian Campbell <i...@debian.org>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Bug #916602 patch by Ian Campbell <i...@debian.org>
+## DP:
+## DP: find issues a warning when `traverse_fs = "false"` is combined with
+## DP: pruning:
+## DP:     find: warning: you have specified the -xdev option after a non-option argument -regex, but options are not positional (-xdev affects tests specified before it as well as those specified after it).  Please specify options before other arguments.
+## DP:
+## DP: Resolve this by moving the use of `-xdev` before the `-regex` calls
+## DP: produced by pruning. However it is not possible move the `-fstype` used
+## DP: for the `traverse_fs = "local"` case (or, presumably, "all" although I
+## DP: did not test this) since this changes the semantics and therefore the set
+## DP: of files backed up in my testing.
+
+@DPATCH@
+--- a/flexbackup
++++ b/flexbackup
+@@ -2890,11 +2890,11 @@ sub optioncheck {
+     # Traverse mountpoints?
+     &checkvar(\$cfg::traverse_fs,'traverse_fs','false local all','false');
+     if ($cfg::traverse_fs eq "local") {
+-	$::mountpoint_flag = "! -fstype nfs ! -fstype smbfs ! -fstype bind ! -fstype proc ! -fstype devpts ! -fstype devfs ! -fstype tmpfs";
++	$::late_mountpoint_flag = "! -fstype nfs ! -fstype smbfs ! -fstype bind ! -fstype proc ! -fstype devpts ! -fstype devfs ! -fstype tmpfs";
+     } elsif ($cfg::traverse_fs eq "all") {
+-	$::mountpoint_flag = "! -fstype proc ! -fstype devpts ! -fstype devfs ! -fstype tmpfs";
++	$::late_mountpoint_flag = "! -fstype proc ! -fstype devpts ! -fstype devfs ! -fstype tmpfs";
+     } else {
+-	$::mountpoint_flag = "-xdev";
++	$::early_mountpoint_flag = "-xdev";
+     }
+ 
+     # Block size
+@@ -4842,7 +4842,11 @@ sub file_list_cmd {
+ 	$prunekey = $dir;
+     }
+ 
++    if (defined($::early_mountpoint_flag)) {
++	$cmd .= "$::early_mountpoint_flag ";
++    }
++
+     if ($::prune{$prunekey}) {
+ 	# FreeBSD needs -E (above) and no backslashes around the (|) chars
+ 	if ($::uname =~ /FreeBSD/) {
+ 	    $cmd .= '-regex "\./(';
+@@ -4861,7 +4865,9 @@ sub file_list_cmd {
+ 	$cmd .= "-depth ";
+     }
+ 
+-    $cmd .= "$::mountpoint_flag ";
++    if (defined($::late_mountpoint_flag)) {
++	$cmd .= "$::late_mountpoint_flag ";
++    }
+     $cmd .= "! -type s ";
+ 
+     if (defined($otherarg)) {

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to