aboutsummaryrefslogtreecommitdiff
path: root/libbb/llist_add_to.c
diff options
context:
space:
mode:
Diffstat (limited to 'libbb/llist_add_to.c')
-rw-r--r--libbb/llist_add_to.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/libbb/llist_add_to.c b/libbb/llist_add_to.c
new file mode 100644
index 000000000..61e53f0c1
--- /dev/null
+++ b/libbb/llist_add_to.c
@@ -0,0 +1,15 @@
1#include <stdlib.h>
2#include <string.h>
3#include "unarchive.h"
4#include "libbb.h"
5
6extern llist_t *llist_add_to(llist_t *old_head, char *new_item)
7{
8 llist_t *new_head;
9
10 new_head = xmalloc(sizeof(llist_t));
11 new_head->data = new_item;
12 new_head->link = old_head;
13
14 return(new_head);
15}