aboutsummaryrefslogtreecommitdiffstats
path: root/src/namespaces.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-01-20 19:08:09 +0000
committerDavid Robillard <d@drobilla.net>2011-01-20 19:08:09 +0000
commit57683c8352e4a545171f28047617df88a6d4c917 (patch)
treee46f7493647a9d95a627d403edcbe6cdf7d4e8da /src/namespaces.c
parentf0c50e7461641d060c783e1f0fb1b74b3c175054 (diff)
downloadserd-57683c8352e4a545171f28047617df88a6d4c917.tar.gz
serd-57683c8352e4a545171f28047617df88a6d4c917.tar.bz2
serd-57683c8352e4a545171f28047617df88a6d4c917.zip
Add serd_string_free to API.
git-svn-id: http://svn.drobilla.net/serd/trunk@13 490d8e77-9747-427b-9fa3-0b8f29cee8a0
Diffstat (limited to 'src/namespaces.c')
-rw-r--r--src/namespaces.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/namespaces.c b/src/namespaces.c
index b14d74c5..6c400a3c 100644
--- a/src/namespaces.c
+++ b/src/namespaces.c
@@ -47,8 +47,8 @@ void
serd_namespaces_free(SerdNamespaces ns)
{
for (size_t i = 0; i < ns->n_namespaces; ++i) {
- free(ns->namespaces[i].name);
- free(ns->namespaces[i].uri);
+ serd_string_free(ns->namespaces[i].name);
+ serd_string_free(ns->namespaces[i].uri);
}
free(ns->namespaces);
free(ns);
@@ -80,7 +80,7 @@ serd_namespaces_add(SerdNamespaces ns,
assert(uri);
SerdNamespace* const record = serd_namespaces_find(ns, name->buf, name->n_chars);
if (record) {
- free(record->uri);
+ serd_string_free(record->uri);
record->uri = serd_string_copy(uri);
} else {
++ns->n_namespaces;