X-Git-Url: http://git.lttng.org./?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Ftrace-kernel.c;h=723ffddd33118ebfd639135decc22bbe1b2c54de;hb=212cee3c8436da6eff40e9ec6aab7fed71fc9a23;hp=22c602ceec7f714ef83666c45b82169b927e7698;hpb=55c9e7cac24318259d4f2549c97f7577b7b52db4;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/trace-kernel.c b/src/bin/lttng-sessiond/trace-kernel.c index 22c602cee..723ffddd3 100644 --- a/src/bin/lttng-sessiond/trace-kernel.c +++ b/src/bin/lttng-sessiond/trace-kernel.c @@ -1,18 +1,8 @@ /* - * Copyright (C) 2011 - David Goulet + * Copyright (C) 2011 David Goulet * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License, version 2 only, - * as published by the Free Software Foundation. + * SPDX-License-Identifier: GPL-2.0-only * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ #define _LGPL_SOURCE @@ -164,28 +154,28 @@ struct ltt_kernel_session *trace_kernel_create_session(void) lks->metadata = NULL; CDS_INIT_LIST_HEAD(&lks->channel_list.head); - lks->tracker_list_pid = lttng_tracker_list_create(); - if (!lks->tracker_list_pid) { + lks->tracker_pid = process_attr_tracker_create(); + if (!lks->tracker_pid) { goto error; } - lks->tracker_list_vpid = lttng_tracker_list_create(); - if (!lks->tracker_list_vpid) { + lks->tracker_vpid = process_attr_tracker_create(); + if (!lks->tracker_vpid) { goto error; } - lks->tracker_list_uid = lttng_tracker_list_create(); - if (!lks->tracker_list_uid) { + lks->tracker_uid = process_attr_tracker_create(); + if (!lks->tracker_uid) { goto error; } - lks->tracker_list_vuid = lttng_tracker_list_create(); - if (!lks->tracker_list_vuid) { + lks->tracker_vuid = process_attr_tracker_create(); + if (!lks->tracker_vuid) { goto error; } - lks->tracker_list_gid = lttng_tracker_list_create(); - if (!lks->tracker_list_gid) { + lks->tracker_gid = process_attr_tracker_create(); + if (!lks->tracker_gid) { goto error; } - lks->tracker_list_vgid = lttng_tracker_list_create(); - if (!lks->tracker_list_vgid) { + lks->tracker_vgid = process_attr_tracker_create(); + if (!lks->tracker_vgid) { goto error; } lks->consumer = consumer_create_output(CONSUMER_DST_LOCAL); @@ -196,12 +186,12 @@ struct ltt_kernel_session *trace_kernel_create_session(void) return lks; error: - lttng_tracker_list_destroy(lks->tracker_list_pid); - lttng_tracker_list_destroy(lks->tracker_list_vpid); - lttng_tracker_list_destroy(lks->tracker_list_uid); - lttng_tracker_list_destroy(lks->tracker_list_vuid); - lttng_tracker_list_destroy(lks->tracker_list_gid); - lttng_tracker_list_destroy(lks->tracker_list_vgid); + process_attr_tracker_destroy(lks->tracker_pid); + process_attr_tracker_destroy(lks->tracker_vpid); + process_attr_tracker_destroy(lks->tracker_uid); + process_attr_tracker_destroy(lks->tracker_vuid); + process_attr_tracker_destroy(lks->tracker_gid); + process_attr_tracker_destroy(lks->tracker_vgid); free(lks); alloc_error: @@ -748,12 +738,12 @@ void trace_kernel_free_session(struct ltt_kernel_session *session) /* Wipe consumer output object */ consumer_output_put(session->consumer); - lttng_tracker_list_destroy(session->tracker_list_pid); - lttng_tracker_list_destroy(session->tracker_list_vpid); - lttng_tracker_list_destroy(session->tracker_list_uid); - lttng_tracker_list_destroy(session->tracker_list_vuid); - lttng_tracker_list_destroy(session->tracker_list_gid); - lttng_tracker_list_destroy(session->tracker_list_vgid); + process_attr_tracker_destroy(session->tracker_pid); + process_attr_tracker_destroy(session->tracker_vpid); + process_attr_tracker_destroy(session->tracker_uid); + process_attr_tracker_destroy(session->tracker_vuid); + process_attr_tracker_destroy(session->tracker_gid); + process_attr_tracker_destroy(session->tracker_vgid); free(session); }