Print this page
pbchk
cleanup port_free_event_local() semantics

*** 23,33 **** * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ /* ! * Copyright (c) 2015 Joyent, Inc. All rights reserved. */ #include <sys/types.h> #include <sys/systm.h> #include <sys/cred.h> --- 23,33 ---- * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ /* ! * Copyright 2020 Joyent, Inc. */ #include <sys/types.h> #include <sys/systm.h> #include <sys/cred.h>
*** 1404,1414 **** if (pev->portkev_flags & PORT_KEV_FREE) { /* Just discard event */ list_remove(glist, pev); pev->portkev_flags &= ~(PORT_CLEANUP_DONE); if (PORT_FREE_EVENT(pev)) ! port_free_event_local(pev, 0); tnent--; continue; } /* move event data to copyout list */ --- 1404,1414 ---- if (pev->portkev_flags & PORT_KEV_FREE) { /* Just discard event */ list_remove(glist, pev); pev->portkev_flags &= ~(PORT_CLEANUP_DONE); if (PORT_FREE_EVENT(pev)) ! port_free_event_local(pev, B_TRUE); tnent--; continue; } /* move event data to copyout list */
*** 1452,1462 **** if (pev->portkev_flags & PORT_KEV_FREE) { /* Just discard event */ list_remove(glist, pev); pev->portkev_flags &= ~(PORT_CLEANUP_DONE); if (PORT_FREE_EVENT(pev)) ! port_free_event_local(pev, 0); tnent--; continue; } /* move event data to copyout list */ --- 1452,1462 ---- if (pev->portkev_flags & PORT_KEV_FREE) { /* Just discard event */ list_remove(glist, pev); pev->portkev_flags &= ~(PORT_CLEANUP_DONE); if (PORT_FREE_EVENT(pev)) ! port_free_event_local(pev, B_TRUE); tnent--; continue; } /* move event data to copyout list */
*** 1624,1634 **** pkevp->portkev_flags = flags; return (error); } } if (free_event) ! port_free_event_local(pkevp, 0); return (0); } #ifdef _SYSCALL32_IMPL /* --- 1624,1634 ---- pkevp->portkev_flags = flags; return (error); } } if (free_event) ! port_free_event_local(pkevp, B_TRUE); return (0); } #ifdef _SYSCALL32_IMPL /*
*** 1679,1689 **** pkevp->portkev_flags = flags; return (error); } } if (free_event) ! port_free_event_local(pkevp, 0); return (0); } #endif /* _SYSCALL32_IMPL */ /* --- 1679,1689 ---- pkevp->portkev_flags = flags; return (error); } } if (free_event) ! port_free_event_local(pkevp, B_TRUE); return (0); } #endif /* _SYSCALL32_IMPL */ /*