infect: initialize struct to avoid CLANG_WARNING

Using scan-build there is a warning about

 infect.c:231:17: warning: The left operand of '!=' is a garbage value
                 if (ss->state != 'Z') {

which is a false positive as every process will have a 'Status' field,
but initializing the structure makes the clang analyzer silent.

Signed-off-by: Adrian Reber <areber@redhat.com>
This commit is contained in:
Adrian Reber 2020-10-13 07:21:19 +00:00 committed by Andrei Vagin
parent ee048e1489
commit 7db0bb69e7

View file

@ -105,7 +105,7 @@ err_parse:
int compel_stop_task(int pid)
{
int ret;
struct seize_task_status ss;
struct seize_task_status ss = {};
ret = compel_interrupt_task(pid);
if (ret == 0)