ref: 4c1d32b6aac406b43dcb63541117ebddb0d1c42c
dir: /libc/lladd.c/
#include <u.h> #include <err.h> #include <mem.h> int lladd(ll_t *last, void *data) { ll_t *temp = malloc(sizeof(ll_t*)); temp->val = data; temp->next = nil; if(last->next != nil) { return LL_ERR; } last->next = temp; return OK; }