fs-sink-trace.c: lttng_validate_datetime(): ignore deprecated decl.
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Wed, 2 Oct 2019 18:25:49 +0000 (14:25 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Fri, 4 Oct 2019 16:52:40 +0000 (12:52 -0400)
Disable `deprecated-declarations` compiler warnings for
lttng_validate_datetime() because we're using `GTimeVal` and
g_time_val_from_iso8601() which are deprecated since GLib 2.56
(Babeltrace supports older versions too).

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
Change-Id: I4da3bda550b3fd7d7ede13ff3b78ec78ad6f7839
Reviewed-on: https://review.lttng.org/c/babeltrace/+/2121
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Francis Deslauriers <francis.deslauriers@efficios.com>
src/plugins/ctf/fs-sink/fs-sink-trace.c

index 16d9241ac559bb6c8a5c8a7936c55169cc86c7dd..b64c62ed3fc2cb0076e1dd8184e09c7e6c2ca5b6 100644 (file)
@@ -133,6 +133,15 @@ GString *make_unique_trace_path(const char *path)
        return unique_path;
 }
 
+/*
+ * Disable `deprecated-declarations` warnings for
+ * lttng_validate_datetime() because we're using `GTimeVal` and
+ * g_time_val_from_iso8601() which are deprecated since GLib 2.56
+ * (Babeltrace supports older versions too).
+ */
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+
 /*
  * Validate that the input string `datetime` is an ISO8601-compliant string (the
  * format used by LTTng in the metadata).
@@ -162,6 +171,8 @@ end:
        return ret;
 }
 
+#pragma GCC diagnostic pop
+
 static
 int append_lttng_trace_path_ust_uid(const struct fs_sink_trace *trace,
                GString *path, const bt_trace *tc)
This page took 0.024883 seconds and 4 git commands to generate.