goto end;
}
- ret = lttng_strncpy(local_exclusions->names[i], string,
- sizeof(local_exclusions->names[i]));
+ ret = lttng_strncpy(LTTNG_EVENT_EXCLUSION_NAME_AT(local_exclusions, i), string,
+ sizeof(LTTNG_EVENT_EXCLUSION_NAME_AT(local_exclusions, i)));
if (ret) {
ret = -1;
goto end;
goto end;
}
- ret = lttng_strncpy(event_ctx->u.perf_counter.name, name, name_len);
+ ret = lttng_strncpy(event_ctx->u.perf_counter.name, name,
+ sizeof(event_ctx->u.perf_counter.name));
if (ret) {
consumed = -1;
goto end;