[Rpm-maint] [rpm-software-management/rpm] Implement a separate lock for the keystore (PR #4123)

Michal Domonkos notifications at github.com
Mon Mar 30 15:38:06 UTC 2026


@dmnks commented on this pull request.



> @@ -153,11 +161,7 @@ int rpmtsRebuildDB(rpmts ts)
 	    rc = rpmdbRebuild(ts->rootDir, NULL, NULL, rebuildflags);
 	rpmtxnEnd(txn);
     }
-    /* Re-create lock file */
-    rpmtsLockFree(ts);
-    txn = rpmtxnBegin(ts, RPMTXN_WRITE);
-    if (txn)
-	rpmtxnEnd(txn);
+    ensureKrlock(ts);

Not sure how big of a deal this is, but `ts` is not checked for `NULL` here (whereas it previously was). It seems like we are checking it elsewhere in this function (and the functions it calls).

Now, passing a `NULL` transaction to the rebuild API call sounds pointless, but still... API is API 😅 

WDYT?

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/4123?email_source=notifications&email_token=ADLPZU6ZIQAXCPGSMMML4ND4TKIF5A5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTIMBTGE2TCMRVGI22M4TFMFZW63VKON2WE43DOJUWEZLEUVSXMZLOOS6XA4S7OJSXM2LFO5PW433UNFTGSY3BORUW63TTL5RWY2LDNM#pullrequestreview-4031512525
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/4123/review/4031512525 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20260330/6cace92f/attachment.htm>


More information about the Rpm-maint mailing list