Processed: Re: Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-03-02 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 + pending
Bug #889728 [release.debian.org] stretch-pu: package bareos/16.2.4-3+deb9u2
Added tag(s) pending.

-- 
889728: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=889728
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems



Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-03-02 Thread Adam D. Barratt
Control: tags -1 + pending

On Mon, 2018-02-26 at 20:51 +0100, Felix Geyer wrote:
> On 23.02.2018 18:30, Adam D. Barratt wrote:
> > Control: tags -1 + confirmed
> > 
> > On Tue, 2018-02-06 at 13:45 +0100, Felix Geyer wrote:
> > > I'd like to fix bug #889040 in stretch:
> > > 
> > > * Fix backups failing with "No Volume name given".
> > >   - Backport upstream commit: Don't return empty volname if
> > > volume is
> > > on
> > > unwanted vols list.
> > > 
> > 
> > Please go ahead.
> 
> Thanks, uploaded.

Flagged for acceptance.

Regards,

Adam



Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-02-26 Thread Felix Geyer
On 23.02.2018 18:30, Adam D. Barratt wrote:
> Control: tags -1 + confirmed
> 
> On Tue, 2018-02-06 at 13:45 +0100, Felix Geyer wrote:
>> I'd like to fix bug #889040 in stretch:
>>
>> * Fix backups failing with "No Volume name given".
>>   - Backport upstream commit: Don't return empty volname if volume is
>> on
>> unwanted vols list.
>>
> 
> Please go ahead.

Thanks, uploaded.

Felix



Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-02-23 Thread Adam D. Barratt
Control: tags -1 + confirmed

On Tue, 2018-02-06 at 13:45 +0100, Felix Geyer wrote:
> I'd like to fix bug #889040 in stretch:
> 
> * Fix backups failing with "No Volume name given".
>   - Backport upstream commit: Don't return empty volname if volume is
> on
> unwanted vols list.
> 

Please go ahead.

Regards,

Adam



Processed: Re: Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-02-23 Thread Debian Bug Tracking System
Processing control commands:

> tags -1 + confirmed
Bug #889728 [release.debian.org] stretch-pu: package bareos/16.2.4-3+deb9u2
Added tag(s) confirmed.

-- 
889728: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=889728
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems



Bug#889728: stretch-pu: package bareos/16.2.4-3+deb9u2

2018-02-06 Thread Felix Geyer
Package: release.debian.org
Severity: normal
Tags: stretch
User: release.debian@packages.debian.org
Usertags: pu

Hi,

I'd like to fix bug #889040 in stretch:

* Fix backups failing with "No Volume name given".
  - Backport upstream commit: Don't return empty volname if volume is on
unwanted vols list.

The bug doesn't affect jessie and is already fixed in testing/unstable.
A debdiff is attached.

Felix
diff -Nru bareos-16.2.4/debian/changelog bareos-16.2.4/debian/changelog
--- bareos-16.2.4/debian/changelog  2017-07-27 20:58:49.0 +0200
+++ bareos-16.2.4/debian/changelog  2018-02-02 10:58:25.0 +0100
@@ -1,3 +1,11 @@
+bareos (16.2.4-3+deb9u2) stretch; urgency=medium
+
+  * Fix backups failing with "No Volume name given". (Closes: #889040)
+- Backport upstream commit: Don't return empty volname if volume is on
+  unwanted vols list.
+
+ -- Felix Geyer   Fri, 02 Feb 2018 10:58:25 +0100
+
 bareos (16.2.4-3+deb9u1) stretch; urgency=medium
 
   * Fix permissions of bareos-dir logrotate config on upgrade. (Closes: 
#864926)
diff -Nru bareos-16.2.4/debian/patches/fix-no-volume-name-given 
bareos-16.2.4/debian/patches/fix-no-volume-name-given
--- bareos-16.2.4/debian/patches/fix-no-volume-name-given   1970-01-01 
01:00:00.0 +0100
+++ bareos-16.2.4/debian/patches/fix-no-volume-name-given   2018-01-30 
10:02:18.0 +0100
@@ -0,0 +1,38 @@
+From d1ff29b3988a7c0aed3c0394ccfb3904f0588ddf Mon Sep 17 00:00:00 2001
+From: Philipp Storz 
+Date: Tue, 25 Apr 2017 10:50:44 +0200
+Subject: [PATCH] Don't return empty volname if volume is on unwanted vols list
+
+When the volume was on the unwanted_list, the loop was
+continued but the number of sql rows was not checked, so that
+the code continued and returned an empty volumename.
+
+Fixes #691: Backup job fails with "No Volume name given."
+---
+ src/cats/sql_find.c | 11 ++-
+ 1 file changed, 10 insertions(+), 1 deletion(-)
+
+diff --git a/src/cats/sql_find.c b/src/cats/sql_find.c
+index ef716b820..c354c8a98 100644
+--- a/src/cats/sql_find.c
 b/src/cats/sql_find.c
+@@ -435,9 +435,18 @@ int db_find_next_volume(JCR *jcr, B_DB *mdb, int item, 
bool InChanger, MEDIA_DBR
+   }
+ 
+   /*
+-   * See if this is not on the unwanted volumes list.
++   * Skip if volume is on unwanted volumes list.
++   * We need to reduce the number of rows by one
++   * and jump out if no more rows are available
+*/
+   if (unwanted_volumes && is_on_unwanted_volumes_list(row[1], 
unwanted_volumes)) {
++ Dmsg1(50, "Volume %s is on unwanted_volume_list, skipping\n", 
row[1]);
++ num_rows-- ;
++ if ( num_rows <= 0) {
++Dmsg1(50, "No more volumes in result, bailing out\n", row[1]);
++sql_free_result(mdb);
++goto bail_out;
++ }
+  continue;
+   }
+ 
diff -Nru bareos-16.2.4/debian/patches/series 
bareos-16.2.4/debian/patches/series
--- bareos-16.2.4/debian/patches/series 2017-07-27 20:58:49.0 +0200
+++ bareos-16.2.4/debian/patches/series 2018-01-30 10:02:41.0 +0100
@@ -1,3 +1,4 @@
 dont-generate-debian-files
 disable-fstype-test
 fix-sha1-file-corruption
+fix-no-volume-name-given