Bug#410501: destar: Conf files are not saved if there's not writing access to zaptel.conf

Tzafrir Cohen tzafrir.cohen at xorcom.com
Mon Feb 12 09:35:52 UTC 2007


On Sun, Feb 11, 2007 at 11:53:44PM -0800, Steve Langasek wrote:
> On Sun, Feb 11, 2007 at 02:09:08AM -0500, Alejandro Rios P. wrote:
> > Package: destar
> > Version: 0.2.0-3
> > Severity: grave
> > Tags: patch
> > Justification: renders package unusable
> 
> > There was a bad conditional expresion on one dpatch file edited on last
> > package upload. Here's the fix to the bug:
> 
> > --- zaptel.dpatch       2007-02-11 00:05:55.000000000 -0500
> > +++ zaptel.dpatch.patch 2007-02-11 01:59:41.000000000 -0500
> > @@ -12,7 +12,7 @@
> >         for _fn,cnf in configlets.asterisk_configfiles:
> > 		if _fn == 'op_server.cfg' and panelutils.isConfigured() != 1:
> > 			continue
> > -+              if not os.access("/etc/zaptel.conf", os.O_RDWR):
> > ++              if _fn == 'zaptel.conf' and not os.access("/etc/zaptel.conf", os.O_RDWR):
> >  +			continue
> > 		try:
> > 			cnf.write()
> 
> Sorry, in what sense does this make the package unusable?  Is it because the
> package's dependencies don't ensure that zaptel.conf will exist?

First off, I actually wanted to test removing the default zaptel.conf
from Debian. See http://bugs.debian.org/383081 .

DeStar works by rewirting the entire asterisk configuration. One of
those configuration files is /etc/zaptel.conf . 

Unlike the others, zaptel.conf is actually mainly used by root, and thus
it is quite acceptable that the system administrator would not like
destar to rewrite it. 

So a check was added to the loop that writes config files:

  If we can't write to zaptel.conf, do nothing.

Only this test intended to be:

  If we can't write to zaptel.conf, don't write to zaptel.conf.

-- 
               Tzafrir Cohen       
icq#16849755                    jabber:tzafrir at jabber.org
+972-50-7952406           mailto:tzafrir.cohen at xorcom.com       
http://www.xorcom.com  iax:guest at local.xorcom.com/tzafrir



More information about the Pkg-voip-maintainers mailing list