aboutta have dead battery

This commit is contained in:
Brett Weiland 2023-10-27 08:20:18 -05:00
parent eb86bdacd8
commit cdf430be43

View File

@ -31,12 +31,12 @@ static struct pwm_event {
((struct pwm_event *)(char *)member_ptr - member_offset)
#define MEMBER_FROM_EVENT(event_ptr, member_offset) \
((struct link_pair *)(char *)event_
((struct link_pair *)(char *)event_ptr + member_offset)
static void list_insert(struct link_pair *new_links, struct link_pair *prev_links, size_t parent_offset) {
new_links->next = prev_links->next;
new_links->prev = EVENT_FROM_MEMBER(prev_links, parent_offset);
((struct link_pair *)(char *)prev_links->next + parent_offset)->prev =
MEMBER_FROM_EVENT()->prev =
EVENT_FROM_MEMBER(new_links, parent_offset); //GYAAAAGH
prev_links->next = EVENT_FROM_MEMBER(prev_links, parent_offset);
}