mirror of
https://github.com/emqx/neuron.git
synced 2026-10-26 03:40:01 +08:00
Merge pull request #2331 from ZhouBox/main
fix bug:json incref when some sub apps
This commit is contained in:
@@ -2134,6 +2134,15 @@ static int report_callback(void *usr_data)
|
||||
|
||||
utarray_foreach(group->apps, sub_app_t *, app)
|
||||
{
|
||||
|
||||
utarray_foreach(data->tags, neu_resp_tag_value_meta_t *,
|
||||
tag_value)
|
||||
{
|
||||
if (tag_value->value.type == NEU_TYPE_CUSTOM) {
|
||||
json_incref(tag_value->value.value.json);
|
||||
}
|
||||
}
|
||||
|
||||
if (group->driver->adapter.cb_funs.responseto(
|
||||
&group->driver->adapter, &header, data, app->addr) !=
|
||||
0) {
|
||||
@@ -2151,6 +2160,13 @@ static int report_callback(void *usr_data)
|
||||
}
|
||||
}
|
||||
|
||||
utarray_foreach(data->tags, neu_resp_tag_value_meta_t *, tag_value)
|
||||
{
|
||||
if (tag_value->value.type == NEU_TYPE_CUSTOM) {
|
||||
json_decref(tag_value->value.value.json);
|
||||
}
|
||||
}
|
||||
|
||||
if (trans_trace) {
|
||||
neu_otel_scope_set_span_end_time(trans_scope, neu_time_ns());
|
||||
neu_otel_trace_set_expected_span_num(trans_trace, app_num);
|
||||
|
||||
Reference in New Issue
Block a user