Force usage of assert() condition when NDEBUG is defined
[lttng-tools.git] / src / bin / lttng / commands / set_session.c
index 32e9a5d645763056ad430e6a791decb4a4439082..fb42d14d5d5e5b931485383c71c291c52e30821e 100644 (file)
@@ -1,18 +1,8 @@
 /*
- * Copyright (C) 2011 David Goulet <david.goulet@polymtl.ca>
+ * Copyright (C) 2011 David Goulet <david.goulet@polymtl.ca>
  *
- * 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
@@ -23,7 +13,6 @@
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <unistd.h>
-#include <assert.h>
 
 #include <common/mi-lttng.h>
 
 
 static char *opt_session_name;
 
+#ifdef LTTNG_EMBED_HELP
+static const char help_msg[] =
+#include <lttng-set-session.1.h>
+;
+#endif
+
 enum {
        OPT_HELP = 1,
        OPT_LIST_OPTIONS,
@@ -52,8 +47,8 @@ static int mi_print(char *session_name)
 {
        int ret;
 
-       assert(writer);
-       assert(session_name);
+       LTTNG_ASSERT(writer);
+       LTTNG_ASSERT(session_name);
 
        /*
         * Open a sessions element
This page took 0.025968 seconds and 4 git commands to generate.