On C Linked Lists

There are two basic styles of double-linked lists in C; I’ll call them ring style and linear style. The Linux kernel has ring-style, defined in include/linux/list.h.  You declare a ‘struct list_head’ and everyone who wants to be in the list puts a ‘struct list_head list’ in their structure (struct list_node in CCAN’s version).  This forms …