diff options
author | David Robillard <d@drobilla.net> | 2025-03-12 08:41:13 -0400 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2025-03-16 20:26:22 -0400 |
commit | 21b14df24458f00f520ce514fc7b928f44016fe2 (patch) | |
tree | 2ba9db15a7afc515c04aa78fc257d24a29a6cfe7 /test/test_writer.c | |
parent | 5cbdb2d0563613ffda76fc32f9a6357d3d2bee4b (diff) | |
download | serd-21b14df24458f00f520ce514fc7b928f44016fe2.tar.gz serd-21b14df24458f00f520ce514fc7b928f44016fe2.tar.bz2 serd-21b14df24458f00f520ce514fc7b928f44016fe2.zip |
Check that test values are non-null before use
Diffstat (limited to 'test/test_writer.c')
-rw-r--r-- | test/test_writer.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/test_writer.c b/test/test_writer.c index 7f8d2f94..00fdc459 100644 --- a/test/test_writer.c +++ b/test/test_writer.c @@ -40,6 +40,7 @@ test_write_long_literal(void) "<http://example.org/s>\n" "\t<http://example.org/p> \"\"\"hello \"\"\\\"world\"\"\\\"!\"\"\" .\n"; + assert(out); assert(!strcmp((char*)out, expected)); serd_free(out); } @@ -112,6 +113,7 @@ test_write_nested_anon(void) "\t\t<http://example.org/p4> <http://example.org/o4>\n" "\t] .\n"; + assert(out); assert(!strcmp((char*)out, expected)); serd_free(out); } @@ -290,6 +292,7 @@ test_chunk_sink(void) serd_writer_free(writer); uint8_t* out = serd_chunk_sink_finish(&chunk); + assert(out); assert(!strcmp((const char*)out, "@base <http://example.org/base> .\n")); serd_free(out); serd_env_free(env); |