From d16a2fc987f009cb08a0e60e1f71ba54ec2ac078 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Tue, 18 Jun 2019 15:11:56 +0200 Subject: [PATCH] xbps_init: fix a logic error. Initialize rv to avoid a logic error. Found by clang-analyzer. Bug Summary File: lib/initend.c Warning: line 101, column 10 The left operand of '<' is a garbage value --- lib/initend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/initend.c b/lib/initend.c index 17a4d3b6..9a64409d 100644 --- a/lib/initend.c +++ b/lib/initend.c @@ -45,7 +45,7 @@ xbps_init(struct xbps_handle *xhp) { char *buf; const char *repodir, *native_arch; - int rv; + int rv = 0; size_t size; assert(xhp != NULL);