nostrdb

an unfairly fast embedded nostr database backed by lmdb
git clone git://jb55.com/nostrdb
Log | Files | Refs | Submodules | README | LICENSE

commit 39f36f9284dc92a51f1c3acb8ba497186252d1bb
parent d7cac21e2884370c2a87c5533636e2caf7e1ef1c
Author: William Casarin <jb55@jb55.com>
Date:   Mon,  4 Dec 2023 14:55:53 -0800

cursor: silence utf8 warnings

Diffstat:
Mcursor.h | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/cursor.h b/cursor.h @@ -523,7 +523,7 @@ static inline int parse_utf8_char(struct cursor *cursor, unsigned int *code_poin remaining_bytes = 0; *utf8_length = 1; // Assume 1 byte length for unrecognized UTF-8 characters // TODO: We need to gracefully handle unrecognized UTF-8 characters - printf("Invalid UTF-8 byte: %x\n", *code_point); + //printf("Invalid UTF-8 byte: %x\n", *code_point); *code_point = ((first_byte & 0xF0) << 6); // Prevent testing as punctuation return 0; // Invalid first byte } @@ -634,7 +634,7 @@ static inline int consume_until_boundary(struct cursor *cur) { if (!parse_utf8_char(cur, &c, utf8_char_length)) { if (!is_right_boundary(c)){ // TODO: We should work towards handling all UTF-8 characters. - printf("Invalid UTF-8 code point: %x\n", c); + //printf("Invalid UTF-8 code point: %x\n", c); } } }