Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.openwrt.org/project/libubox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Crispin <blogic@openwrt.org>2013-11-18 14:15:19 +0400
committerFelix Fietkau <nbd@openwrt.org>2013-11-18 15:25:21 +0400
commitbc8167eb99bc6febc96f4dab0bbce32186f30c16 (patch)
tree91d4dbb3a0045a1ab0af58da6c3728ababf44cf3 /safe_list.c
parenta34c8f6918c291275ded2b6fd9b94ac91722ded2 (diff)
runqueue: add a function that allows adding jobs to the front of the runqueue
Signed-off-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'safe_list.c')
-rw-r--r--safe_list.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/safe_list.c b/safe_list.c
index f26b4dd..16f57e0 100644
--- a/safe_list.c
+++ b/safe_list.c
@@ -86,6 +86,12 @@ void safe_list_add(struct safe_list *list, struct safe_list *head)
list_add_tail(&list->list, &head->list);
}
+void safe_list_add_first(struct safe_list *list, struct safe_list *head)
+{
+ list->i = NULL;
+ list_add(&list->list, &head->list);
+}
+
void safe_list_del(struct safe_list *list)
{
struct safe_list_iterator *i, *next_i, **tail;