]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: ot: add argument for default value to vars_get_by_name()
authorWilly Tarreau <w@1wt.eu>
Fri, 3 Sep 2021 12:20:32 +0000 (14:20 +0200)
committerWilly Tarreau <w@1wt.eu>
Fri, 3 Sep 2021 12:21:40 +0000 (14:21 +0200)
The API was extended by commit e352b9dac ("MINOR: vars: make vars_get_by_*
support an optional default value") but I didn't notice that opentracing
was using it, so it broke the build. No backport needed.

addons/ot/src/vars.c

index fff54acac568b4646ff42d90df1c9a840f9e63f1..dd823b1a71f564f9b4e513753e8ef317d0bea5a4 100644 (file)
@@ -452,7 +452,7 @@ int flt_ot_var_get(struct stream *s, const char *scope, const char *prefix, cons
        (void)memset(&smp, 0, sizeof(smp));
        (void)smp_set_owner(&smp, s->be, s->sess, s, opt | SMP_OPT_FINAL);
 
-       if (vars_get_by_name(var_name, retval, &smp)) {
+       if (vars_get_by_name(var_name, retval, &smp, NULL)) {
                retval = flt_ot_sample_to_str(&(smp.data), var_value, sizeof(var_value), err);
                if (retval != -1)
                        FLT_OT_DBG(3, "data type %d: '%s' = '%s'", smp.data.type, var_name, var_value);