diff options
author | Stelios Fragkakis <52996999+stelfrag@users.noreply.github.com> | 2021-10-11 21:24:58 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-11 21:24:58 +0300 |
commit | c8b513a0459150a3583e3516af74c3040b3cc12d (patch) | |
tree | 53cb5eb3e892046da7ec54e1abad79a91cf064b9 /database | |
parent | 2e6107b2be44448e490334e0db44524d39a8304c (diff) |
Fix chart config overflow (#11645)
Diffstat (limited to 'database')
-rw-r--r-- | database/rrdset.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/database/rrdset.c b/database/rrdset.c index 95e7eb0c2b..e4701e3b9e 100644 --- a/database/rrdset.c +++ b/database/rrdset.c @@ -699,11 +699,11 @@ RRDSET *rrdset_create_custom( // ------------------------------------------------------------------------ // compose the config_section for this chart - char config_section[RRD_ID_LENGTH_MAX + 1]; + char config_section[RRD_ID_LENGTH_MAX + GUID_LEN + 2]; if(host == localhost) strcpy(config_section, fullid); else - snprintfz(config_section, RRD_ID_LENGTH_MAX, "%s/%s", host->machine_guid, fullid); + snprintfz(config_section, RRD_ID_LENGTH_MAX + GUID_LEN + 1, "%s/%s", host->machine_guid, fullid); // ------------------------------------------------------------------------ // get the options from the config, we need to create it |