llist_add_to.c 286 B

123456789101112131415
  1. #include <stdlib.h>
  2. #include <string.h>
  3. #include "unarchive.h"
  4. #include "libbb.h"
  5. extern llist_t *llist_add_to(llist_t *old_head, char *new_item)
  6. {
  7. llist_t *new_head;
  8. new_head = xmalloc(sizeof(llist_t));
  9. new_head->data = new_item;
  10. new_head->link = old_head;
  11. return(new_head);
  12. }