summaryrefslogtreecommitdiff
path: root/ldpd/accept.c
diff options
context:
space:
mode:
authorDonatas Abraitis <donatas.abraitis@gmail.com>2021-10-04 19:25:18 +0300
committerDonatas Abraitis <donatas.abraitis@gmail.com>2021-10-04 19:25:18 +0300
commitdc4a902689e46717e2f7c34d3546e7b5b78cb3d1 (patch)
treeded05cd7901bcf6ef934decfa27fab4884b79002 /ldpd/accept.c
parentc34d552dd5fe8a6821ec5efee2eb463fe3108424 (diff)
ldpd: Do not explicitly set the thread pointer to NULL
FRR should only ever use the appropriate THREAD_ON/THREAD_OFF semantics. This is espacially true for the functions we end up calling the thread for. Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
Diffstat (limited to 'ldpd/accept.c')
-rw-r--r--ldpd/accept.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/ldpd/accept.c b/ldpd/accept.c
index 9bba0f5ddd..e8d3976ee9 100644
--- a/ldpd/accept.c
+++ b/ldpd/accept.c
@@ -58,7 +58,6 @@ accept_add(int fd, int (*cb)(struct thread *), void *arg)
av->arg = arg;
LIST_INSERT_HEAD(&accept_queue.queue, av, entry);
- av->ev = NULL;
thread_add_read(master, accept_cb, av, av->fd, &av->ev);
log_debug("%s: accepting on fd %d", __func__, fd);
@@ -86,7 +85,6 @@ accept_pause(void)
{
log_debug(__func__);
accept_unarm();
- accept_queue.evt = NULL;
thread_add_timer(master, accept_timeout, NULL, 1, &accept_queue.evt);
}
@@ -105,7 +103,6 @@ accept_arm(void)
{
struct accept_ev *av;
LIST_FOREACH(av, &accept_queue.queue, entry) {
- av->ev = NULL;
thread_add_read(master, accept_cb, av, av->fd, &av->ev);
}
}
@@ -122,7 +119,6 @@ static int
accept_cb(struct thread *thread)
{
struct accept_ev *av = THREAD_ARG(thread);
- av->ev = NULL;
thread_add_read(master, accept_cb, av, av->fd, &av->ev);
av->accept_cb(thread);