As mentionned in the comment, the tx_qrings and rxbufs members of receiver struct must be pointers to pointers! Modify the functions responsible of their allocations consequently. Note that this code could work because sizeof rxbuf and sizeof tx_qrings are greater than the size of pointer!