diff options
author | Timotej S <6674623+underhood@users.noreply.github.com> | 2022-03-16 14:41:21 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-16 14:41:21 +0100 |
commit | 121129aaeb60aa40d9c2572979cda98d12daccf5 (patch) | |
tree | a88a068020e67c183d885eb28db2a8cadf7b770c | |
parent | 472bf451601a1aec1b1d17810502a0a83e676df6 (diff) |
ensure claim_id is sent always lowercase (#12423)
-rw-r--r-- | claim/claim.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/claim/claim.c b/claim/claim.c index c919fa3bdc..e68134d5d4 100644 --- a/claim/claim.c +++ b/claim/claim.c @@ -161,7 +161,9 @@ void load_claiming_state(void) freez(claimed_id); claimed_id = NULL; } - localhost->aclk_state.claimed_id = claimed_id; + + localhost->aclk_state.claimed_id = mallocz(UUID_STR_LEN); + uuid_unparse_lower(uuid, localhost->aclk_state.claimed_id); invalidate_node_instances(&localhost->host_uuid, claimed_id ? &uuid : NULL); store_claim_id(&localhost->host_uuid, claimed_id ? &uuid : NULL); @@ -172,6 +174,8 @@ void load_claiming_state(void) return; } + freez(claimed_id); + info("File '%s' was found. Setting state to AGENT_CLAIMED.", filename); netdata_cloud_setting = appconfig_get_boolean(&cloud_config, CONFIG_SECTION_GLOBAL, "enabled", 1); #endif |