aboutsummaryrefslogtreecommitdiffstats
path: root/src/node.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2023-05-04 14:58:45 -0400
committerDavid Robillard <d@drobilla.net>2023-12-02 18:49:08 -0500
commit551faf54e35c757144204bf7a7949c0f7d0a20a3 (patch)
treee8f761fc6361c75dd443d6e91806d27025d4102a /src/node.c
parentc3bc111f7fb2a44e068e5250f7823352e44c76dc (diff)
downloadserd-551faf54e35c757144204bf7a7949c0f7d0a20a3.tar.gz
serd-551faf54e35c757144204bf7a7949c0f7d0a20a3.tar.bz2
serd-551faf54e35c757144204bf7a7949c0f7d0a20a3.zip
Make SerdBuffer an output stream
Diffstat (limited to 'src/node.c')
-rw-r--r--src/node.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/node.c b/src/node.c
index 79fcc38e..189b02d9 100644
--- a/src/node.c
+++ b/src/node.c
@@ -532,11 +532,11 @@ serd_new_file_uri(const SerdStringView path, const SerdStringView hostname)
{
SerdBuffer buffer = {NULL, 0U};
- serd_write_file_uri(path, hostname, serd_buffer_sink, &buffer);
- serd_buffer_sink_finish(&buffer);
+ serd_write_file_uri(path, hostname, serd_buffer_write, &buffer);
+ serd_buffer_close(&buffer);
const size_t length = buffer.len;
- const char* const string = serd_buffer_sink_finish(&buffer);
+ const char* const string = (char*)buffer.buf;
SerdNode* const node = serd_new_string(serd_substring(string, length));
free(buffer.buf);