mirror of
https://github.com/emqx/neuron.git
synced 2026-10-17 04:40:42 +08:00
@@ -20,7 +20,7 @@
|
||||
#ifndef _NEU_DEFINE_H_
|
||||
#define _NEU_DEFINE_H_
|
||||
|
||||
#define NEU_TAG_NAME_LEN 32
|
||||
#define NEU_TAG_NAME_LEN 48
|
||||
#define NEU_TAG_ADDRESS_LEN 128
|
||||
#define NEU_TAG_DESCRIPTION_LEN 128
|
||||
#define NEU_GROUP_NAME_LEN 32
|
||||
|
||||
@@ -502,7 +502,7 @@ int neu_adapter_driver_add_tag(neu_adapter_driver_t *driver, const char *group,
|
||||
int ret = NEU_ERR_SUCCESS;
|
||||
group_t *find = NULL;
|
||||
|
||||
if (strlen(tag->name) > NEU_TAG_NAME_LEN) {
|
||||
if (strlen(tag->name) >= NEU_TAG_NAME_LEN) {
|
||||
return NEU_ERR_TAG_NAME_TOO_LONG;
|
||||
}
|
||||
|
||||
@@ -568,7 +568,7 @@ int neu_adapter_driver_update_tag(neu_adapter_driver_t *driver,
|
||||
int ret = NEU_ERR_SUCCESS;
|
||||
group_t *find = NULL;
|
||||
|
||||
if (strlen(tag->name) > NEU_TAG_NAME_LEN) {
|
||||
if (strlen(tag->name) >= NEU_TAG_NAME_LEN) {
|
||||
return NEU_ERR_TAG_NAME_TOO_LONG;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user