summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugin.c4
-rw-r--r--src/slv2_internal.h2
-rw-r--r--src/world.c9
3 files changed, 5 insertions, 10 deletions
diff --git a/src/plugin.c b/src/plugin.c
index c1cd384..57de06c 100644
--- a/src/plugin.c
+++ b/src/plugin.c
@@ -36,14 +36,14 @@
/* private
* ownership of uri is taken */
SLV2Plugin
-slv2_plugin_new(SLV2World world, SLV2Value uri, librdf_uri* bundle_uri, librdf_uri* binary_uri)
+slv2_plugin_new(SLV2World world, SLV2Value uri, librdf_uri* bundle_uri)
{
assert(bundle_uri);
struct _SLV2Plugin* plugin = malloc(sizeof(struct _SLV2Plugin));
plugin->world = world;
plugin->plugin_uri = uri;
plugin->bundle_uri = slv2_value_new_librdf_uri(world, bundle_uri);
- plugin->binary_uri = binary_uri ? slv2_value_new_librdf_uri(world, binary_uri) : NULL;
+ plugin->binary_uri = NULL;
plugin->plugin_class = NULL;
plugin->data_uris = slv2_values_new();
plugin->ports = raptor_new_sequence((void (*)(void*))&slv2_port_free, NULL);
diff --git a/src/slv2_internal.h b/src/slv2_internal.h
index 753867e..87c1d53 100644
--- a/src/slv2_internal.h
+++ b/src/slv2_internal.h
@@ -69,7 +69,7 @@ struct _SLV2Plugin {
librdf_model* rdf;
};
-SLV2Plugin slv2_plugin_new(SLV2World world, SLV2Value uri, librdf_uri* bundle_uri, librdf_uri* binary_uri);
+SLV2Plugin slv2_plugin_new(SLV2World world, SLV2Value uri, librdf_uri* bundle_uri);
void slv2_plugin_load(SLV2Plugin p);
void slv2_plugin_free(SLV2Plugin plugin);
void slv2_plugin_get_port_float_values(SLV2Plugin p,
diff --git a/src/world.c b/src/world.c
index 82edbad..6433ffb 100644
--- a/src/world.c
+++ b/src/world.c
@@ -510,8 +510,7 @@ slv2_world_load_all(SLV2World world)
"PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\n"
"PREFIX slv2: <http://drobilla.net/ns/slv2#>\n"
"SELECT DISTINCT ?plugin ?data ?bundle ?binary\n"
- "WHERE { ?plugin a :Plugin; slv2:bundleURI ?bundle; rdfs:seeAlso ?data\n"
- "OPTIONAL { ?plugin :binary ?binary } }\n";
+ "WHERE { ?plugin a :Plugin; slv2:bundleURI ?bundle; rdfs:seeAlso ?data }\n";
//"ORDER BY ?plugin\n";
librdf_query* q = librdf_new_query(world->world, "sparql",
@@ -527,18 +526,16 @@ slv2_world_load_all(SLV2World world)
librdf_uri* data_uri = librdf_node_get_uri(data_node);
librdf_node* bundle_node = librdf_query_results_get_binding_value(results, 2);
librdf_uri* bundle_uri = librdf_node_get_uri(bundle_node);
- librdf_node* binary_node = librdf_query_results_get_binding_value(results, 3);
assert(plugin_uri);
assert(data_uri);
- librdf_uri* binary_uri = binary_node ? librdf_node_get_uri(binary_node) : NULL;
SLV2Value uri = slv2_value_new_librdf_uri(world, plugin_uri);
SLV2Plugin plugin = slv2_plugins_get_by_uri(world->plugins, uri);
// Create a new SLV2Plugin
if (!plugin) {
- plugin = slv2_plugin_new(world, uri, bundle_uri, binary_uri);
+ plugin = slv2_plugin_new(world, uri, bundle_uri);
raptor_sequence_push(world->plugins, plugin);
// FIXME: Slow! ORDER BY broken in certain versions of redland?
raptor_sequence_sort(world->plugins, slv2_plugin_compare_by_uri);
@@ -555,8 +552,6 @@ slv2_world_load_all(SLV2World world)
librdf_free_node(plugin_node);
librdf_free_node(data_node);
librdf_free_node(bundle_node);
- if (binary_node)
- librdf_free_node(binary_node);
librdf_query_results_next(results);
}