From 685f544918e4287abea4a04c69502df5b17d4f36 Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Tue, 20 Feb 2018 10:40:22 +0100 Subject: [PATCH] chrt: fix compiler warning [-Wmaybe-uninitialized] Signed-off-by: Karel Zak --- schedutils/chrt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/schedutils/chrt.c b/schedutils/chrt.c index 3d21c4387..b08c78ed8 100644 --- a/schedutils/chrt.c +++ b/schedutils/chrt.c @@ -207,7 +207,7 @@ static const char *get_policy_name(int policy) static void show_sched_pid_info(struct chrt_ctl *ctl, pid_t pid) { - int policy, reset_on_fork = 0, prio = 0; + int policy = -1, reset_on_fork = 0, prio = 0; #ifdef SCHED_DEADLINE uint64_t deadline = 0, runtime = 0, period = 0; #endif