Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Makefile.analyzers
Original file line number Diff line number Diff line change
Expand Up @@ -688,12 +688,12 @@ endif
$(BUILD_TOP)/tests/lwip/%.o: $(LWIP_TOP)/%.c
@[ -d $(dir $@) ] || mkdir -p $(dir $@)
ifeq "$(V)" "1"
$(CC) $(CFLAGS) -Wno-conversion -c $< -o $@
$(CC) $(CFLAGS) -Wno-conversion -Wno-format -c $< -o $@
else
ifndef VERY_QUIET
@echo "$(CC) ... -o $@"
endif
@$(CC) $(CFLAGS) -Wno-conversion -c $< -o $@
@$(CC) $(CFLAGS) -Wno-conversion -Wno-format -c $< -o $@
endif

$(BUILD_TOP)/tests/freertos/%.o: $(FREERTOS_TOP)/%.c
Expand Down
4 changes: 2 additions & 2 deletions tests/unittests.c
Original file line number Diff line number Diff line change
Expand Up @@ -4494,7 +4494,7 @@ static int test_json(const char *fname, const char *extra_fname) {

if ((ret = json_dom_parse(WOLFSENTRY_CONTEXT_ARGS_OUT_EX(wolfsentry_get_allocator(wolfsentry)), test_json_document, (size_t)st.st_size, &centijson_config,
0 /* dom_flags */, &p_root, &json_pos)) < 0) {
void *p = memchr((const char *)(test_json_document + json_pos.offset), '\n', (size_t)st.st_size - json_pos.offset);
const void *p = memchr((const char *)(test_json_document + json_pos.offset), '\n', (size_t)st.st_size - json_pos.offset);
int linelen = p ? ((int)((unsigned char *)p - (test_json_document + json_pos.offset)) + (int)json_pos.column_number - 1) :
(((int)st.st_size - (int)json_pos.offset) + (int)json_pos.column_number - 1);
if (WOLFSENTRY_ERROR_DECODE_SOURCE_ID(ret) == WOLFSENTRY_SOURCE_ID_UNSET)
Expand Down Expand Up @@ -5076,7 +5076,7 @@ static int test_json_corpus(void) {

if ((ret = json_dom_parse(WOLFSENTRY_CONTEXT_ARGS_OUT_EX(wolfsentry_get_allocator(wolfsentry)), scenario, (size_t)st.st_size, &centijson_config,
dom_flags, &p_root, &json_pos)) < 0) {
void *p = memchr((const char *)(scenario + json_pos.offset), '\n', (size_t)st.st_size - json_pos.offset);
const void *p = memchr((const char *)(scenario + json_pos.offset), '\n', (size_t)st.st_size - json_pos.offset);
int linelen = p ? ((int)((unsigned char *)p - (scenario + json_pos.offset)) + (int)json_pos.column_number - 1) :
(((int)st.st_size - (int)json_pos.offset) + (int)json_pos.column_number - 1);
if (WOLFSENTRY_ERROR_DECODE_SOURCE_ID(ret) == WOLFSENTRY_SOURCE_ID_UNSET)
Expand Down