diff options
| author | Garrett D'Amore <garrett@damore.org> | 2018-02-14 14:50:04 -0800 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2018-02-14 18:28:36 -0800 |
| commit | 45bc175ef9278c175d2fc3a0678b49b18e74c449 (patch) | |
| tree | b1838778ee898112f28b35178364068c6f48c9b4 /tests/base64.c | |
| parent | 8f93750ed2a6aaa1749eb689ddf119280f9aac7a (diff) | |
| download | nng-45bc175ef9278c175d2fc3a0678b49b18e74c449.tar.gz nng-45bc175ef9278c175d2fc3a0678b49b18e74c449.tar.bz2 nng-45bc175ef9278c175d2fc3a0678b49b18e74c449.zip | |
fixes #234 Investigate enabling more verbose compiler warnings
We enabled verbose compiler warnings, and found a lot of issues.
Some of these were even real bugs. As a bonus, we actually save
some initialization steps in the compat layer, and avoid passing
some variables we don't need.
Diffstat (limited to 'tests/base64.c')
| -rw-r--r-- | tests/base64.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/base64.c b/tests/base64.c index 714bd4b2..eac84df2 100644 --- a/tests/base64.c +++ b/tests/base64.c @@ -1,6 +1,6 @@ // -// Copyright 2017 Staysail Systems, Inc. <info@staysail.tech> -// Copyright 2017 Capitar IT Group BV <info@capitar.com> +// Copyright 2018 Staysail Systems, Inc. <info@staysail.tech> +// Copyright 2018 Capitar IT Group BV <info@capitar.com> // // This software is supplied under the terms of the MIT License, a // copy of which should be located in the distribution where this @@ -45,7 +45,7 @@ TestMain("Base64 Verification", { for (i = 0; (dec = cases[i].decoded) != NULL; i++) { rv = nni_base64_encode(dec, strlen(dec), buf, 1024); So(rv >= 0); - So(rv == strlen(cases[i].encoded)); + So(rv == (int) strlen(cases[i].encoded)); buf[rv] = 0; So(strcmp(buf, cases[i].encoded) == 0); } @@ -61,7 +61,7 @@ TestMain("Base64 Verification", { rv = nni_base64_decode( enc, strlen(enc), (void *) buf, 1024); So(rv >= 0); - So(rv == strlen(cases[i].decoded)); + So(rv == (int) strlen(cases[i].decoded)); buf[rv] = 0; So(strcmp(buf, cases[i].decoded) == 0); } |
