Skip to content
Commit a161ffe4 authored by Tom Rix's avatar Tom Rix Committed by Bjorn Andersson
Browse files

soc: qcom: initialize local variable



clang static analysis reports this problem

pdr_interface.c:596:6: warning: Branch condition evaluates
  to a garbage value
        if (!req.service_path[0])
            ^~~~~~~~~~~~~~~~~~~~

This check that req.service_path was set in an earlier loop.
However req is a stack variable and its initial value
is undefined.

So initialize req to 0.

Fixes: fbe639b4 ("soc: qcom: Introduce Protection Domain Restart helpers")
Reviewed-by: default avatarSibi Sankar <sibis@codeaurora.org>
Signed-off-by: default avatarTom Rix <trix@redhat.com>
Link: https://lore.kernel.org/r/20200819184637.15648-1-trix@redhat.com


Signed-off-by: default avatarBjorn Andersson <bjorn.andersson@linaro.org>
parent 903b0834
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment