From b84ffc176d3ab90a5dd42e406f84b2207f2782ca Mon Sep 17 00:00:00 2001
From: Nick Alcock <nick.alcock@oracle.com>
Date: Wed, 19 Jun 2024 14:06:26 +0100
Subject: libctf: fix testsuite bugs revealed by -Wall

Most of these are harmless, but some of the type confusions and especially
a missing ctf_strerror() on an error path were actual bugs that could
have resulted in test failures crashing rather than printing an error
message.

libctf/
	* testsuite/libctf-lookup/enumerator-iteration.c: Fix type
        confusion, signedness confusion and a missing ctf_errmsg().
	* testsuite/libctf-regression/libctf-repeat-cu-main.c: Return 0 from
        the test function.
	* testsuite/libctf-regression/open-error-free.c: Fix signedness
        confusion.
	* testsuite/libctf-regression/zrewrite.c: Remove unused label.
---
 libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c')

diff --git a/libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c b/libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c
index bfbaf0c..c1f2f63 100644
--- a/libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c
+++ b/libctf/testsuite/libctf-regression/libctf-repeat-cu-main.c
@@ -2,4 +2,4 @@ typedef short ret_t;
 int a (void);
 int b (void);
 int c (void);
-int blah (void) { a(); b(); c(); }
+int blah (void) { a(); b(); c(); return 0; }
-- 
cgit v1.1