X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Fbin%2Flttng-consumerd%2Flttng-consumerd.c;h=bd53db5897d3861b42da7e43f8d86b046027ee10;hp=d97dae2d1dc43667624964316a5b11b8d646e3f0;hb=86eff0042bf0b9e6277b281c4f3a680d997790d2;hpb=0ca413e056cf24ec5424cde5c78227138b0782c7 diff --git a/src/bin/lttng-consumerd/lttng-consumerd.c b/src/bin/lttng-consumerd/lttng-consumerd.c index d97dae2d1..bd53db589 100644 --- a/src/bin/lttng-consumerd/lttng-consumerd.c +++ b/src/bin/lttng-consumerd/lttng-consumerd.c @@ -1,19 +1,9 @@ /* - * Copyright (C) 2011 - Julien Desfossez - * Mathieu Desnoyers + * Copyright (C) 2011 Julien Desfossez + * Copyright (C) 2011 Mathieu Desnoyers * - * 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 @@ -311,6 +301,10 @@ int main(int argc, char **argv) rcu_register_thread(); + if (run_as_create_worker(argv[0], NULL, NULL) < 0) { + goto exit_set_signal_handler; + } + if (set_signal_handler()) { retval = -1; goto exit_set_signal_handler; @@ -411,10 +405,6 @@ int main(int argc, char **argv) set_ulimit(); } - if (run_as_create_worker(argv[0]) < 0) { - goto exit_init_data; - } - /* create the consumer instance with and assign the callbacks */ ctx = lttng_consumer_create(opt_type, lttng_consumer_read_subbuffer, NULL, lttng_consumer_on_recv_stream, NULL);