[pkg-bacula-devel] [pkg-bacula-commits] [SCM] Bacula, a network backup, recovery and verification program branch, master, updated. debian/5.2.6+dfsg-2-22-g85d99ef

Luca Capello luca at pca.it
Fri Aug 3 14:32:47 UTC 2012


Hi Alexander!

On Wed, 01 Aug 2012 14:14:53 +0200, Alexander Golovko wrote:
> The following commit has been merged in the master branch:
> commit 85d99ef87085872fbdca7cb098362ebdc2e8cd18
> Author: Alexander Golovko <alexandro at ankalagon.ru>
> Date:   Wed Aug 1 16:12:07 2012 +0400
>
>     fix files left after packages purge.
>     
>     Fix bat.conf and tray-monitor.conf purging

The description is not correct, since...

> diff --git a/debian/bacula-traymonitor.postrm b/debian/bacula-console-qt.postrm
> similarity index 62%
> copy from debian/bacula-traymonitor.postrm
> copy to debian/bacula-console-qt.postrm
> index 219fa81..0b24c1c 100644
> --- a/debian/bacula-traymonitor.postrm
> +++ b/debian/bacula-console-qt.postrm
> @@ -3,14 +3,10 @@
>  set -e
>  
>  
> -CFGDIR=/etc/bacula
> -CFGFILE="tray-monitor.conf"
> -
> -
>  case "$1" in
> -    purge)
> -        rm -f $CFGDIR/$CFGFILE.*
> -    ;;
> +  purge)
> +    rm -f /etc/bacula/bat.conf /etc/bacula/bat.conf.*

...you are removing old dpkg conffiles, which AFAIK is wrong: as soon as
a file gets its .dpkg* extensions, we should stop caring about it.
Moreover, what if a local admin did `cp /etc/bacula/bat.conf{,.LUCA}?
This copied file must never be removed.

Looking at the Git commit, I would say that:

1) the behavior changed only for *real* conffiles, i.e. without any
   extra .dpkg* extension, so if my comment above is correct previous
   behavior was already broken;

2) what is the rationale for removing the variables?  I find them easier
   to be read and if you want to remove other stuff you can do the
   following:

     rm -rf $CFGDIR/$CFGFILE $CFGDIR/$CFGFILE.*

3) please do no change the style at the same time, I know the style is
   not consistent all over the bacula sources, but it should be taken
   care with a single commit, not spread among unrelated ones.

> +  * debian/bacula-console-qt.postrm, debian/bacula-traymonitor.postrm:
> +    + fix files left after packages purge (thanks to piuparts).

Hint: given that you fixed it for an already reported bug (#682733), why
do not you group everything in a single debian/changelog line, also
keeping the style?  ;-)

  <http://anonscm.debian.org/gitweb/?p=pkg-bacula/bacula.git;a=commitdiff;h=13530290124ea967e28baa304370c904a048fbfe>

As a side note: we failed to detect this bug before because
bacula-common.postrm contains an `rm -rf /etc/bacula`, thus doing an
`apt-get --purge autoremove bacula-console` seemed fine.

However, I still question bacula-common.postrm's behavior, for the same
reason of bat.conf.LUCA above.

Thx, bye,
Gismo / Luca
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-bacula-devel/attachments/20120803/1b7222fb/attachment.pgp>


More information about the pkg-bacula-devel mailing list