diff options
Diffstat (limited to 'src/n3.c')
-rw-r--r-- | src/n3.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1178,7 +1178,7 @@ read_object(SerdReader* reader, ReadContext* ctx, bool emit, bool* ate_dot) o->flags = flags; } - if (!ret && emit && simple) { + if (!ret && emit && simple && o) { ret = emit_statement(reader, *ctx, o); } else if (!ret && !emit) { ctx->object = o; @@ -1408,6 +1408,7 @@ read_base(SerdReader* reader, bool sparql, bool token) SerdNode* uri = NULL; TRY(st, read_IRIREF(reader, &uri)); + serd_node_zero_pad(uri); TRY(st, serd_sink_write_base(reader->sink, uri)); read_ws_star(reader); @@ -1448,6 +1449,8 @@ read_prefixID(SerdReader* reader, bool sparql, bool token) SerdNode* uri = NULL; TRY(st, read_IRIREF(reader, &uri)); + serd_node_zero_pad(name); + serd_node_zero_pad(uri); st = serd_sink_write_prefix(reader->sink, name, uri); if (!sparql) { |