We have very few users of the appctx's private field which was introduced
prior to the split of the CLI. Unfortunately it was not removed after the
end. This commit simply introduces hlua_cli->fcn which is the pointer to
the Lua function that the Lua code used to store in this private pointer.
struct {
struct hlua hlua;
struct task *task;
+ struct hlua_function *fcn;
} hlua_cli;
struct {
struct hlua hlua;
const char *error;
hlua = &appctx->ctx.hlua_cli.hlua;
+ appctx->ctx.hlua_cli.fcn = private;
fcn = private;
- appctx->private = private;
/* Create task used by signal to wakeup applets.
* We use the same wakeup fonction than the Lua applet_tcp and
hlua = &appctx->ctx.hlua_cli.hlua;
si = appctx->owner;
- fcn = appctx->private;
+ fcn = appctx->ctx.hlua_cli.fcn;
/* If the stream is disconnect or closed, ldo nothing. */
if (unlikely(si->state == SI_ST_DIS || si->state == SI_ST_CLO))