aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/node_syntax.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/node_syntax.c b/src/node_syntax.c
index 10483188..913277d5 100644
--- a/src/node_syntax.c
+++ b/src/node_syntax.c
@@ -83,15 +83,15 @@ serd_node_to_syntax(const SerdNode* node, const SerdSyntax syntax)
st = serd_writer_finish(writer);
}
- serd_buffer_sink_finish(&buffer);
+ char* const result = serd_buffer_sink_finish(&buffer);
serd_writer_free(writer);
serd_byte_sink_free(bsink);
serd_world_free(world);
if (st) {
- serd_free(buffer.buf);
+ serd_free(result);
return NULL;
}
- return (char*)buffer.buf;
+ return result;
}