[Rpm-maint] [rpm-software-management/rpm] rpmKeyring: Support keys with the same key ID (PR #3398)

Panu Matilainen notifications at github.com
Wed Oct 23 13:16:49 UTC 2024


Being outside loop is not a crime, it's just something to generally avoid if possible.

On that note, ignore my earlier mumble about references and copies (as you did) - the thing you get from equal_range() is an iterator, not the item itself. "item" is not the best of names for it in all these cases. "it" is the c++ iterator counterpart for "int i" idiom.

rpmKeyringVerifySig2() is unnecessarily convoluted though. Just push all the lints into the vector and on non-ok final result log it all in a loop, and use a c++ string so you don't need to manually clear it at the end. The no-key sanity check should only ever occur if we didn't find a key at all, not on any failure, and should use the same exact return code handling as the keyed version - you'll want a small helper function to handle the lints collection and all.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/3398#issuecomment-2432141376
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/pull/3398/c2432141376 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20241023/3c67ace6/attachment.html>


More information about the Rpm-maint mailing list