mirror of
https://github.com/emqx/neuron.git
synced 2026-10-17 04:40:42 +08:00
chore(log): limit string length
This commit is contained in:
@@ -179,8 +179,9 @@ static inline char *neu_value_str(neu_type_e type, neu_value_u value)
|
||||
value.boolean);
|
||||
break;
|
||||
case NEU_TYPE_STRING: {
|
||||
snprintf(str, sizeof(str), "type: %s, value: %s", neu_type_string(type),
|
||||
value.str);
|
||||
snprintf(str, sizeof(str), "type: %s, value: %c%c%c",
|
||||
neu_type_string(type), value.str[0], value.str[1],
|
||||
value.str[2]);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user