mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
Fix userspace build after r302235: do not expose bool field of the
structure, change it to int. The real fix is to sanitize user-visible definitions in sys/event.h, e.g. the affected struct knlist is of no use for userspace programs. Reported and tested by: jkim Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Approved by: re (gjb)
This commit is contained in:
parent
725441f69b
commit
9eb3f14324
2 changed files with 3 additions and 3 deletions
|
|
@ -2204,7 +2204,7 @@ knlist_init(struct knlist *knl, void *lock, void (*kl_lock)(void *),
|
|||
else
|
||||
knl->kl_assert_unlocked = kl_assert_unlocked;
|
||||
|
||||
knl->kl_autodestroy = false;
|
||||
knl->kl_autodestroy = 0;
|
||||
SLIST_INIT(&knl->kl_list);
|
||||
}
|
||||
|
||||
|
|
@ -2255,7 +2255,7 @@ knlist_detach(struct knlist *knl)
|
|||
{
|
||||
|
||||
KNL_ASSERT_LOCKED(knl);
|
||||
knl->kl_autodestroy = true;
|
||||
knl->kl_autodestroy = 1;
|
||||
if (knlist_empty(knl)) {
|
||||
knlist_destroy(knl);
|
||||
free(knl, M_KQUEUE);
|
||||
|
|
|
|||
|
|
@ -159,7 +159,7 @@ struct knlist {
|
|||
void (*kl_assert_locked)(void *);
|
||||
void (*kl_assert_unlocked)(void *);
|
||||
void *kl_lockarg; /* argument passed to lock functions */
|
||||
bool kl_autodestroy;
|
||||
int kl_autodestroy;
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue