diff options
-rw-r--r-- | src/instance.c | 6 | ||||
-rw-r--r-- | src/lib.c | 8 | ||||
-rw-r--r-- | src/state.c | 6 |
3 files changed, 10 insertions, 10 deletions
diff --git a/src/instance.c b/src/instance.c index 80bbb99..66f5d13 100644 --- a/src/instance.c +++ b/src/instance.c @@ -38,7 +38,7 @@ lilv_plugin_instantiate(const LilvPlugin* plugin, LilvLib* lib = lilv_lib_open(plugin->world, lib_uri, bundle_path, features); if (!lib) { - free(bundle_path); + lilv_free(bundle_path); return NULL; } @@ -47,7 +47,7 @@ lilv_plugin_instantiate(const LilvPlugin* plugin, SerdURI base_uri; if (serd_uri_parse((const uint8_t*)bundle_uri_str, &base_uri)) { lilv_lib_close(lib); - free(bundle_path); + lilv_free(bundle_path); return NULL; } @@ -95,7 +95,7 @@ lilv_plugin_instantiate(const LilvPlugin* plugin, } free(local_features); - free(bundle_path); + lilv_free(bundle_path); if (result) { // Failed to instantiate @@ -42,7 +42,7 @@ lilv_lib_open(LilvWorld* world, void* lib = dlopen(lib_path, RTLD_NOW); if (!lib) { LILV_ERRORF("Failed to open library %s (%s)\n", lib_path, dlerror()); - free(lib_path); + lilv_free(lib_path); return NULL; } @@ -57,17 +57,17 @@ lilv_lib_open(LilvWorld* world, desc = ldf(bundle_path, features); if (!desc) { LILV_ERRORF("Call to `lv2_lib_descriptor' in %s failed\n", lib_path); - free(lib_path); + lilv_free(lib_path); return NULL; } } else if (!df) { LILV_ERRORF("No `lv2_descriptor' or `lv2_lib_descriptor' in %s\n", lib_path); dlclose(lib); - free(lib_path); + lilv_free(lib_path); return NULL; } - free(lib_path); + lilv_free(lib_path); LilvLib* llib = (LilvLib*)malloc(sizeof(LilvLib)); llib->world = world; diff --git a/src/state.c b/src/state.c index 79199e4..a29581a 100644 --- a/src/state.c +++ b/src/state.c @@ -1117,7 +1117,7 @@ lilv_state_delete(LilvWorld* world, if (unlink(file_path)) { LILV_ERRORF("Failed to remove %s (%s)\n", file_path, strerror(errno)); } - free(file_path); + lilv_free(file_path); } // Remove any existing manifest entries for this state @@ -1140,14 +1140,14 @@ lilv_state_delete(LilvWorld* world, LILV_ERRORF("Failed to remove %s (%s)\n", dir_path, strerror(errno)); } - free(dir_path); + lilv_free(dir_path); } else { // Still something in the manifest, reload bundle lilv_world_load_bundle(world, bundle); } sord_free(model); - free(manifest_path); + lilv_free(manifest_path); lilv_node_free(manifest); lilv_node_free(bundle); |