mirror of
https://github.com/ddidderr/wuffs.git
synced 2026-11-21 16:47:28 +01:00
Have read_u8 honor the limit.
This commit is contained in:
1 parent
7a3ddbc025
commit
0088c7e257
4 files changed
+120
-44
No files matched your search
@@ -156,7 +156,7 @@ bool buf1s_equal(const char* prefix,
|
||||
puffs_base_buf1* got,
|
||||
puffs_base_buf1* want) {
|
||||
if (!got || !want) {
|
||||
FAIL("%sbufs1_equal: NULL argument", prefix);
|
||||
FAIL("%sbuf1s_equal: NULL argument", prefix);
|
||||
return false;
|
||||
}
|
||||
char* msg = fail_msg;
|
||||
@@ -167,10 +167,10 @@ bool buf1s_equal(const char* prefix,
|
||||
}
|
||||
}
|
||||
if (got->wi != want->wi) {
|
||||
INCR_FAIL(msg, "%sbufs1_equal: wi: got %zu, want %zu.\n", prefix, got->wi,
|
||||
INCR_FAIL(msg, "%sbuf1s_equal: wi: got %zu, want %zu.\n", prefix, got->wi,
|
||||
want->wi);
|
||||
} else if (i < got->wi) {
|
||||
INCR_FAIL(msg, "%sbufs1_equal:\n", prefix);
|
||||
INCR_FAIL(msg, "%sbuf1s_equal:\n", prefix);
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user