Bill Allombert wrote:
> On Sun, Mar 30, 2008 at 04:11:01PM -0400, Joey Hess wrote:
> > diff --new-file -ur old/menu-2.1.38/update-menus/update-menus.cc 
> > menu-2.1.39/update-menus/update-menus.cc
> > --- old/menu-2.1.38/update-menus/update-menus.cc    2008-03-03 
> > 15:13:45.000000000 -0500
> > +++ menu-2.1.39/update-menus/update-menus.cc        2008-03-30 
> > 14:46:53.000000000 -0400
> > @@ -802,14 +804,32 @@
> >  
> >    
> >    // Check if the dpkg lock is taken
> > -  if (check_dpkglock()) {
> > +  if (check_dpkglock())
> > +  {
> > +    if (! config.real)
> > +    {
> > +      // Try to use dpkg-trigger to trigger the menu update later.
> > +      if (system("dpkg-trigger /usr/share/menu >/dev/null 2>&1") == 0)
> > +      {
> > +        // Success, so no need to do anything now.
> > +        exit(0);
> > +      }
> > +    }
> 
> Hello Joey,
> I wonder if this is correct. 
> What happen if the user run update-menus manually while the dpkg lock is
> held ? 'dpkg-trigger /usr/share/menu' will fail because
> DPKG_MAINTSCRIPT_PACKAGE is not set.
> 
> Maybe we should do
> dpkg-trigger --by-package=menu /usr/share/menu
> to cover this case.

That sounds right.

-- 
see shy jo

Attachment: signature.asc
Description: Digital signature

Reply via email to