git: cdb58f9d04cf - main - ksiginfo_tryfree(): change return type to bool
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 20 Aug 2022 17:34:57 UTC
The branch main has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=cdb58f9d04cfb99d00e757ee769f8c2c3efcff89 commit cdb58f9d04cfb99d00e757ee769f8c2c3efcff89 Author: Konstantin Belousov <kib@FreeBSD.org> AuthorDate: 2022-08-17 16:58:46 +0000 Commit: Konstantin Belousov <kib@FreeBSD.org> CommitDate: 2022-08-20 17:33:18 +0000 ksiginfo_tryfree(): change return type to bool The function result is already used as bool. Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Differential revision: https://reviews.freebsd.org/D36207 --- sys/kern/kern_sig.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index 27aff0998c90..ea3c36a57f32 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -380,14 +380,14 @@ ksiginfo_free(ksiginfo_t *ksi) uma_zfree(ksiginfo_zone, ksi); } -static __inline int +static __inline bool ksiginfo_tryfree(ksiginfo_t *ksi) { - if (!(ksi->ksi_flags & KSI_EXT)) { + if ((ksi->ksi_flags & KSI_EXT) == 0) { uma_zfree(ksiginfo_zone, ksi); - return (1); + return (true); } - return (0); + return (false); } void