Skip to content

Commit cebbed2

Browse files
committed
Compare RBS strings as binary data
1 parent 5de6ecd commit cebbed2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/string.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,5 +37,5 @@ size_t rbs_string_len(const rbs_string_t self) {
3737
bool rbs_string_equal(const rbs_string_t lhs, const rbs_string_t rhs) {
3838
if (lhs.start == rhs.start && lhs.end == rhs.end) return true;
3939
if (rbs_string_len(lhs) != rbs_string_len(rhs)) return false;
40-
return strncmp(lhs.start, rhs.start, rbs_string_len(lhs)) == 0;
40+
return memcmp(lhs.start, rhs.start, rbs_string_len(lhs)) == 0;
4141
}

0 commit comments

Comments
 (0)