disco: Compare unsigned with unsigned

Removes some warrning when building with -Wextra on RISC-V
This commit is contained in:
Henry Case 2018-12-08 21:33:10 +00:00
parent d13aba56f8
commit 06e0c8df2f
2 changed files with 5 additions and 5 deletions

View File

@ -215,7 +215,7 @@ inline void strobe_clone(const strobe_s *src, strobe_s *dst) {
*/ */
void strobe_print(const strobe_s *strobe) { void strobe_print(const strobe_s *strobe) {
for (int i = 0; i < sizeof(strobe->state); i++) { for (size_t i = 0; i < sizeof(strobe->state); i++) {
printf("%02x", strobe->state.b[i]); printf("%02x", strobe->state.b[i]);
} }
printf("\n"); printf("\n");

View File

@ -98,7 +98,7 @@ void test_NX() {
// debug // debug
printf("sent %zu bytes\n", out_len); printf("sent %zu bytes\n", out_len);
for (int i = 0; i < out_len; i++) { for (size_t i = 0; i < out_len; i++) {
printf("%02x", out[i]); printf("%02x", out[i]);
} }
printf("\n"); printf("\n");
@ -134,7 +134,7 @@ void test_NX() {
// debug // debug
printf("sent %zu bytes:\n", out_len); printf("sent %zu bytes:\n", out_len);
for (int i = 0; i < out_len; i++) { for (size_t i = 0; i < out_len; i++) {
printf("%02x", out[i]); printf("%02x", out[i]);
} }
printf("\n"); printf("\n");
@ -215,7 +215,7 @@ void test_IK() {
// debug // debug
printf("sent %zu bytes\n", out_len); printf("sent %zu bytes\n", out_len);
for (int i = 0; i < out_len; i++) { for (size_t i = 0; i < out_len; i++) {
printf("%02x", out[i]); printf("%02x", out[i]);
} }
printf("\n"); printf("\n");
@ -251,7 +251,7 @@ void test_IK() {
// debug // debug
printf("sent %zu bytes:\n", out_len); printf("sent %zu bytes:\n", out_len);
for (int i = 0; i < out_len; i++) { for (size_t i = 0; i < out_len; i++) {
printf("%02x", out[i]); printf("%02x", out[i]);
} }
printf("\n"); printf("\n");