summaryrefslogtreecommitdiffstats
path: root/sord
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2018-07-22 12:48:37 +0200
committerDavid Robillard <d@drobilla.net>2018-07-22 12:48:37 +0200
commitdbd784ed8ce745badbe71b5ae898b9e5b502c968 (patch)
treea85b650cbd2ac07a54699f83d537f3164418d617 /sord
parente0b3fb3a9722c404da5b374957ebc4f1c941867e (diff)
downloadsord-dbd784ed8ce745badbe71b5ae898b9e5b502c968.tar.gz
sord-dbd784ed8ce745badbe71b5ae898b9e5b502c968.tar.bz2
sord-dbd784ed8ce745badbe71b5ae898b9e5b502c968.zip
Use serd_free
Diffstat (limited to 'sord')
-rw-r--r--sord/sordmm.hpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/sord/sordmm.hpp b/sord/sordmm.hpp
index fdc9c59..ee33289 100644
--- a/sord/sordmm.hpp
+++ b/sord/sordmm.hpp
@@ -522,7 +522,7 @@ Model::load_file(SerdEnv* env,
SerdReader* reader = sord_new_reader(_c_obj, env, syntax, NULL);
serd_reader_read_file(reader, path);
serd_reader_free(reader);
- free(path);
+ serd_free(path);
}
inline SerdStatus
@@ -537,10 +537,10 @@ Model::write_to_file(const std::string& uri, SerdSyntax syntax, SerdStyle style)
FILE* const fd = fopen((const char*)path, "w");
if (!fd) {
fprintf(stderr, "Failed to open file %s\n", path);
- free(path);
+ serd_free(path);
return SERD_ERR_UNKNOWN;
}
- free(path);
+ serd_free(path);
SerdURI base_uri = SERD_URI_NULL;
if (serd_uri_parse((const uint8_t*)uri.c_str(), &base_uri)) {