
Data Fields | |
| int | category |
| struct { | |
| struct eventqent * next | |
| } | eq_next |
| char | eventdata [1] |
| unsigned int | seq |
| struct timeval | tv |
| int | usecount |
Clients have a pointer to the last event processed, and for each of these clients we track the usecount of the elements. If we have a pointer to an entry in the list, it is safe to navigate it forward because elements will not be deleted, but only appended. The worst that can happen is seeing the pointer still NULL.
When the usecount of an element drops to 0, and the element is the first in the list, we can remove it. Removal is done within the main thread, which is woken up for the purpose.
For simplicity of implementation, we make sure the list is never empty.
Definition at line 919 of file manager.c.
| int category |
Definition at line 921 of file manager.c.
Referenced by action_getconfig(), action_getconfigjson(), action_listcategories(), action_waitevent(), append_event(), handle_showmaneventq(), handle_updates(), and process_events().
| struct { ... } eq_next |
| char eventdata[1] |
really variable size, allocated by append_event()
Definition at line 925 of file manager.c.
Referenced by action_waitevent(), append_event(), handle_showmaneventq(), and process_events().
Definition at line 924 of file manager.c.
Referenced by advance_event(), ast_instring(), and load_channelvars().
| unsigned int seq |
sequence number
Definition at line 922 of file manager.c.
Referenced by __ast_manager_event_multichan(), and append_event().
struct timeval tv [read] |
When event was allocated
Definition at line 923 of file manager.c.
Referenced by append_event(), and purge_events().
| int usecount |
# of clients who still need the event
Definition at line 920 of file manager.c.
Referenced by advance_event(), append_event(), grab_last(), handle_showmaneventq(), purge_events(), and session_destructor().
1.5.6