[Rpm-maint] Re: [Suse patch] Don't block signals in ro-mode

Panu Matilainen pmatilai at redhat.com
Fri May 25 10:47:46 UTC 2007


On Fri, 25 May 2007, Panu Matilainen wrote:
>
> With this patch, stale ro-locks are left behind when running as root and 
> interrupted (eg rpm -qa), not good.

...unless private locking is used, which is what Suse does (patch below). 
Isn't this already configurable through %__dbi_foo macros?

 	- Panu -

---

Always use DB_PRIVATE. Should probably be configured instead.

--- ./rpmdb/db3.c.orig	2005-03-23 18:15:28.000000000 +0000
+++ ./rpmdb/db3.c	2006-01-27 20:08:29.000000000 +0000
@@ -1034,6 +1050,9 @@ static int db3open(rpmdb rpmdb, rpmTag r
  #endif
  #endif

+	/* always use fcntl lock */
+	dbi->dbi_eflags |= DB_PRIVATE;
+
  	if (access(dbhome, W_OK) == -1) {

  	    /* dbhome is unwritable, don't attempt DB_CREATE on DB->open ... */



More information about the Rpm-maint mailing list