From: David Carlier Date: Tue, 20 Oct 2026 14:59:03 +0000 (+0100) Subject: BUG/MINOR: deviceatlas: refresh the user-agent evidence id after a reload X-Git-Tag: v3.5-dev10~55 X-Git-Url: https://git.kaiwu.me/?a=commitdiff_plain;h=d6123b0fe99d847543f34fa42be4b5eef05ffb25;p=haproxy.git BUG/MINOR: deviceatlas: refresh the user-agent evidence id after a reload The user-agent evidence id used by da-csv-conv was only computed at init. Ids belong to the data file, so after a hot-reload of a file with a different header list, da-csv-conv could pass a stale id and return wrong or empty properties until restart. This should be backported to lower branches. --- diff --git a/addons/deviceatlas/da.c b/addons/deviceatlas/da.c index 157ebb110..ee2822aaa 100644 --- a/addons/deviceatlas/da.c +++ b/addons/deviceatlas/da.c @@ -335,6 +335,8 @@ static void da_haproxy_checkinst(void) cold = global_deviceatlas.atlasimgptr; global_deviceatlas.atlasimgptr = cnew; global_deviceatlas.atlas = inst; + global_deviceatlas.useragentid = da_atlas_header_evidence_id(&global_deviceatlas.atlas, + "user-agent"); global_deviceatlas.maxhdrlen = maxhdrlen; thread_release(); free(cold);