[Rpm-maint] [rpm-software-management/rpm] 3 cleanup fixes (#359)

Alan Jenkins notifications at github.com
Mon Jun 4 14:30:07 UTC 2018


Agreed, fab7348 removes the need for my commit.

I notice exit() does not seem to be on the list of POSIX signal-safe functions (in contrast with `_exit()`).

I guess in general, if rpm is really trying to clean up inside a signal handler, I'd expect a lot of really hairy edge cases.

E.g. technically I think librpm might also be relying on `_free()` not being inlined (LTO). Otherwise, I think the compiler might have the opportunity to re-order freeing the db _before_ updating `*prev`. Leading to double-free if a signal hits at that point.  https://github.com/rpm-software-management/rpm/blob/fab7348d9a338349e5727f87af734c0e20cfb7ad/lib/rpmdb.c#L421

Thank you for working on rpm.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/359#issuecomment-394375192
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20180604/87512e5c/attachment.html>


More information about the Rpm-maint mailing list