struct buffer_reg_channel *reg_chan;
struct consumer_socket *socket;
+ if (!reg->registry->reg.ust->metadata_key) {
+ /* Skip since no metadata is present */
+ continue;
+ }
+
/* Get consumer socket to use to push the metadata.*/
socket = consumer_find_socket_by_bitness(reg->bits_per_long,
usess->consumer);
SESSION_NAME="tracker"
NR_ITER=100
NUM_GLOBAL_TESTS=2
-NUM_UST_TESTS=256
+NUM_UST_TESTS=265
NUM_KERNEL_TESTS=462
NUM_TESTS=$((NUM_UST_TESTS+NUM_KERNEL_TESTS+NUM_GLOBAL_TESTS))
rm -rf "$trace_path"
}
+function test_event_ust_vpid_untrack_snapshot()
+{
+ local trace_path
+
+ trace_path=$(mktemp -d)
+
+ diag "Test_event_ust_vpid_untrack_snapshot"
+
+ create_lttng_session_ok $SESSION_NAME "$trace_path" "--snapshot"
+
+ enable_ust_lttng_event_ok $SESSION_NAME "$EVENT_NAME"
+
+ prepare_ust_app
+
+ lttng_untrack_ust_ok "--vpid --all"
+
+ start_lttng_tracing_ok
+
+ trace_ust_app
+ lttng_snapshot_record $SESSION_NAME
+
+ stop_lttng_tracing_ok
+ destroy_lttng_session_ok $SESSION_NAME
+
+ snapshot_count=$(find "$trace_path" -name metadata | wc -l)
+ is "$snapshot_count" 0 "Number of snapshot is zero"
+
+ rm -rf "$trace_path"
+}
+
# MUST set TESTDIR before calling those functions
plan_tests $NUM_TESTS
test_event_tracker ust 1 "${EVENT_NAME}" "--vpid --all"
test_event_vpid_tracker ust 1 "${EVENT_NAME}"
+#snapshot untrack vpid
+
+test_event_ust_vpid_untrack_snapshot
+
#pid (backward compat)
#non-matching