aboutsummaryrefslogtreecommitdiff
path: root/libctf/testsuite
diff options
context:
space:
mode:
authorNick Alcock <nick.alcock@oracle.com>2021-01-05 19:34:56 +0000
committerNick Alcock <nick.alcock@oracle.com>2021-01-05 19:34:56 +0000
commit0814dbfbfcc9d92ce6adb42412eb555a24c756d4 (patch)
treec16cce8bc218d19aba965d75d40a177617b73069 /libctf/testsuite
parent70d3120f32281980105169dee74440146e97702e (diff)
downloadgdb-0814dbfbfcc9d92ce6adb42412eb555a24c756d4.zip
gdb-0814dbfbfcc9d92ce6adb42412eb555a24c756d4.tar.gz
gdb-0814dbfbfcc9d92ce6adb42412eb555a24c756d4.tar.bz2
libctf, testsuite: adjust for real return type of ctf_member_count
This returns an int, not a long int or an ssize_t (as one test was inconsistently assuming). libctf/ChangeLog 2021-01-05 Nick Alcock <nick.alcock@oracle.com> * testsuite/libctf-lookup/struct-iteration.c (main): ctf_member_count returns an int.
Diffstat (limited to 'libctf/testsuite')
-rw-r--r--libctf/testsuite/libctf-lookup/struct-iteration.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libctf/testsuite/libctf-lookup/struct-iteration.c b/libctf/testsuite/libctf-lookup/struct-iteration.c
index 0375060..080edfa 100644
--- a/libctf/testsuite/libctf-lookup/struct-iteration.c
+++ b/libctf/testsuite/libctf-lookup/struct-iteration.c
@@ -26,7 +26,7 @@ main (int argc, char *argv[])
const char *name;
ctf_id_t membtype;
ssize_t offset;
- ssize_t icount = 0;
+ int icount = 0;
int err;
if (argc != 2)
@@ -69,8 +69,8 @@ main (int argc, char *argv[])
goto nerr;
if (icount != ctf_member_count (fp, type))
- printf ("member counts differ: %li by direct iteration, "
- "%li by ctf_member_count\n", icount, ctf_member_count (fp, type));
+ printf ("member counts differ: %i by direct iteration, "
+ "%i by ctf_member_count\n", icount, ctf_member_count (fp, type));
ctf_dict_close (fp);
ctf_close (ctf);