]> git.sur5r.net Git - openldap/commitdiff
Add task names to runqueue entries
authorHoward Chu <hyc@openldap.org>
Sat, 23 Apr 2005 00:27:57 +0000 (00:27 +0000)
committerHoward Chu <hyc@openldap.org>
Sat, 23 Apr 2005 00:27:57 +0000 (00:27 +0000)
include/ldap_rq.h
libraries/libldap_r/rq.c

index 4fc9c072bb9e8c7deb2e0d1af7ab0d0fb48be2e5..4d3923b26e527b599e5cfe98396d2915fc0d7b8c 100644 (file)
@@ -27,6 +27,8 @@ typedef struct re_s {
        LDAP_STAILQ_ENTRY(re_s) rnext;
        ldap_pvt_thread_start_t *routine;
        void *arg;
+       char *tname;
+       char *tspec;
 } re_t;
 
 typedef struct runqueue_s {
@@ -40,7 +42,9 @@ ldap_pvt_runqueue_insert(
        struct runqueue_s* rq,
        time_t interval,
        ldap_pvt_thread_start_t* routine,
-       void *arg
+       void *arg,
+       char *tname,
+       char *tspec
 );
 
 LDAP_F( struct re_s* )
index adfaea5641813044aee94feccbef6055e174a885..99daef6ca1baefe6f59ffc54d7b6f8870650e2cb 100644 (file)
@@ -38,7 +38,9 @@ ldap_pvt_runqueue_insert(
        struct runqueue_s* rq,
        time_t interval,
        ldap_pvt_thread_start_t *routine,
-       void *arg
+       void *arg,
+       char *tname,
+       char *tspec
 )
 {
        struct re_s* entry;
@@ -51,6 +53,8 @@ ldap_pvt_runqueue_insert(
                entry->next_sched.tv_usec = 0;
                entry->routine = routine;
                entry->arg = arg;
+               entry->tname = tname;
+               entry->tspec = tspec;
                LDAP_STAILQ_INSERT_TAIL( &rq->task_list, entry, tnext );
        }
        return entry;