Merge pull request #16308 from bluca/root_image_options

service: add new RootImageOptions feature
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2020-08-03 10:04:36 +02:00
committed by GitHub
25 changed files with 465 additions and 15 deletions
+15
View File
@@ -169,3 +169,18 @@
#define LIST_IS_EMPTY(head) \
(!(head))
/* Join two lists tail to head: a->b, c->d to a->b->c->d and de-initialise second list */
#define LIST_JOIN(name,a,b) \
do { \
assert(b); \
if (!(a)) \
(a) = (b); \
else { \
typeof(*(a)) *_head = (b), *_tail; \
LIST_FIND_TAIL(name, (a), _tail); \
_tail->name##_next = _head; \
_head->name##_prev = _tail; \
} \
(b) = NULL; \
} while (false)