From: Willy Tarreau Date: Wed, 15 Jun 2022 14:40:58 +0000 (+0200) Subject: MINOR: applet: always use task_new_on() on applet creation X-Git-Tag: v2.7-dev2~150 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3b7a19c2a65abe3f3461da7e57a55eee29d75e7a;p=thirdparty%2Fhaproxy.git MINOR: applet: always use task_new_on() on applet creation Now that task_new_on() supports negative numbers, there's no need for checking the thread value nor falling back to task_new_anywhere(). --- diff --git a/src/applet.c b/src/applet.c index 47263bcd5c..41ad2fc3dd 100644 --- a/src/applet.c +++ b/src/applet.c @@ -57,11 +57,7 @@ struct appctx *appctx_new_on(struct applet *applet, struct sedesc *sedesc, int t } appctx->sedesc = sedesc; - if (thr >= 0) - appctx->t = task_new_on(thr); - else - appctx->t = task_new_anywhere(); - + appctx->t = task_new_on(thr); if (unlikely(!appctx->t)) goto fail_task; appctx->t->process = task_run_applet;