Aaron Nyholm commented on a discussion on freebsd/sys/kern/kern_event.c: https://gitlab.rtems.org/rtems/pkg/rtems-libbsd/-/merge_requests/71#note_122904 > if (ffd < 0) > error = EBADF; > else { > - if (iop == NULL) > + if (iop == NULL) { > error = fget(td, ffd, > &cap_event_rights, &fp); > - else > + if (!error) { > + > rtems_bsd_libio_iop_drop(kev->ident); > + } This issue is specific to Kqueue as it handles both RTEMS files and Freebsd files. It doesn't need to be replicated elsewhere as the issue is specific to kqueue handling both Freebsd and RTEMS files. This section should only hold the `iop` once but does so twice for Freebsd files. The first hold is `rtems_bsd_libio_iop_hold` which is done for both Freebsd and RTEMS files. Then `fget` also holds the `iop` for Freebsd files. This just corrects that count. -- View it on GitLab: https://gitlab.rtems.org/rtems/pkg/rtems-libbsd/-/merge_requests/71#note_122904 You're receiving this email because of your account on gitlab.rtems.org.
_______________________________________________ bugs mailing list bugs@rtems.org http://lists.rtems.org/mailman/listinfo/bugs