From 6186e5b839c77af387614eec6a1c24053e46c849 Mon Sep 17 00:00:00 2001 From: Jonathan Rajotte Date: Wed, 20 Nov 2019 16:14:39 -0500 Subject: [PATCH] Fix: initialize var_data to NULL MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Remove a false-positive from scan-build. Initialization of var_data_len should have been enough but scan build is not smart enough to understand this. Signed-off-by: Jonathan Rajotte Change-Id: I90cb449f3092db432967a3f2ea5eedb0728b8678 Signed-off-by: Jérémie Galarneau --- src/lib/lttng-ctl/lttng-ctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/lttng-ctl/lttng-ctl.c b/src/lib/lttng-ctl/lttng-ctl.c index cfe437118..95515007c 100644 --- a/src/lib/lttng-ctl/lttng-ctl.c +++ b/src/lib/lttng-ctl/lttng-ctl.c @@ -3134,7 +3134,7 @@ static int lttng_track_untrack_id(struct lttng_handle *handle, { int ret; struct lttcomm_session_msg lsm; - const char *var_data; + const char *var_data = NULL; size_t var_data_len = 0; int value; enum lttng_tracker_id_status status; -- 2.34.1