File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 107
107
108
108
#define LIST_ENTRY (type ) struct { \
109
109
struct type *le_next; \
110
- struct type *le_prev; \
110
+ struct type ** le_prev; \
111
111
}
112
112
113
113
#define LIST_EMPTY (head ) ((head)->lh_first == NULL)
133
133
#define LIST_REMOVE (elm , field ) do { \
134
134
if (LIST_NEXT((elm), field) != NULL) \
135
135
LIST_NEXT((elm), field)->field.le_prev = (elm)->field.le_prev; \
136
+ *(elm)->field.le_prev = LIST_NEXT((elm), field); \
136
137
} while (0)
137
138
138
139
#define LIST_INSERT_HEAD (head , elm , field ) do { \
139
140
if ((LIST_NEXT((elm), field) = LIST_FIRST((head))) != NULL) \
140
- LIST_FIRST((head))->field.le_prev = LIST_NEXT((elm), field); \
141
+ LIST_FIRST((head))->field.le_prev = & LIST_NEXT((elm), field); \
141
142
LIST_FIRST((head)) = (elm); \
142
- (elm)->field.le_prev = LIST_FIRST((head)); \
143
+ (elm)->field.le_prev = & LIST_FIRST((head)); \
143
144
} while (0)
144
145
145
146
#endif // __DISPATCH_SHIMS_SYS_QUEUE__
You can’t perform that action at this time.
0 commit comments