History

kconfig: fix lists definition for C++

The C++ compiler is more strict in that it refuses to assign a void* to a struct list_head*. Fix that by explicitly casting the poisonning constants. (Tested with all 5 frontends, now.)

Yann E. MORIN committed 13 years ago

Commit 21ca3521 parent 23a5dfd1 file · +2 −2Browse files

Unified · Split

scripts/kconfig/list.h+2−2
@@ -125,7 +125,7 @@ static inline void __list_del(struct list_head *prev, struct list_head *next) · 124 unmodified lines
125static inline void list_del(struct list_head *entry)125static inline void list_del(struct list_head *entry)
126{126{
127 __list_del(entry->prev, entry->next);127 __list_del(entry->prev, entry->next);
128 entry->next = LIST_POISON1;128 entry->next = (struct list_head*)LIST_POISON1;
129 entry->prev = LIST_POISON2;129 entry->prev = (struct list_head*)LIST_POISON2;
130}130}
131#endif131#endif