Bug#147872: dpkg: doesn't set /var/lib/dpkg/lock to close on exec
On Thu, 23 May 2002 18:12, Adam Heath wrote:
> On Thu, 23 May 2002 russell@coker.com.au wrote:
> > diff -ru /tmp/dpkg-1.9.21/lib/lock.c ./lib/lock.c
> > --- /tmp/dpkg-1.9.21/lib/lock.c Mon Apr 23 13:29:30 2001
> > +++ ./lib/lock.c Thu May 23 10:32:10 2002
> > @@ -78,7 +78,6 @@
> > ohshit(_("status database area is locked by another process"));
> > ohshite(_("unable to lock dpkg status database"));
> > }
> > - n= fcntl(dblockfd, F_GETFD);
> > - if (n >= 0) fcntl(dblockfd, F_SETFD, n | FD_CLOEXEC);
> > + fcntl(dblockfd, F_SETFD, n | FD_CLOEXEC);
> > push_cleanup(cu_unlockdb,~0, NULL,0, 0);
> > }
>
> ?I'm applying this to HEAD right now. However, I remoed the n | from the
> call, as otherwise I get a warning about n being uninitialized.
Thanks!
As you probably guessed my code was a quick hack that basically works. I'm
glad you cleaned it up before applying it.
--
To UNSUBSCRIBE, email to debian-dpkg-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Reply to: