summaryrefslogtreecommitdiffstats
path: root/src/query.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2006-06-11 18:08:50 +0000
committerDavid Robillard <d@drobilla.net>2006-06-11 18:08:50 +0000
commitaf72224cba09c873c1f8e81d7bd9db9747f9553d (patch)
tree7cc8379be2362ab7312eb50c4020bdd9feb4adfa /src/query.c
parent7fd4168fe8581e46f4ee35cc182db6220b6eed04 (diff)
downloadlilv-af72224cba09c873c1f8e81d7bd9db9747f9553d.tar.gz
lilv-af72224cba09c873c1f8e81d7bd9db9747f9553d.tar.bz2
lilv-af72224cba09c873c1f8e81d7bd9db9747f9553d.zip
Fixed query problems on 64-bit
git-svn-id: http://svn.drobilla.net/lad/libslv2@23 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/query.c')
-rw-r--r--src/query.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/src/query.c b/src/query.c
index 2030735..ddaf648 100644
--- a/src/query.c
+++ b/src/query.c
@@ -35,7 +35,7 @@ slv2_query_header(const SLV2Plugin* p)
"PREFIX doap: <http://usefulinc.com/ns/doap#> \n"
"PREFIX lv2: <http://lv2plug.in/ontology#> \n"
"PREFIX plugin: <"), plugin_uri, U("> \n"),
- U("PREFIX data: <"), data_file_url, U("> \n\n"), 0);
+ U("PREFIX data: <"), data_file_url, U("> \n\n"), NULL);
return query_string;
}
@@ -51,7 +51,7 @@ slv2_query_lang_filter(const uchar* variable)
result = ustrjoin(
//U("FILTER (lang(?value) = \""), lang, U("\")\n"), 0);
U("FILTER( lang(?value) = \""), lang,
- U("\" || lang(?value) = \"\" )\n"), 0);
+ U("\" || lang(?value) = \"\" )\n"), NULL);
}
return result;
@@ -62,16 +62,17 @@ rasqal_query_results*
slv2_plugin_run_query(const SLV2Plugin* p,
const uchar* first, ...)
{
- va_list args_list;
- va_start(args_list, first);
- va_list args_copy;
- va_copy(args_copy, args_list);
/* FIXME: Too much unecessary allocation */
uchar* header = slv2_query_header(p);
- uchar* args_str = vstrjoin(first, args_copy);
- uchar* query_str = ustrjoin(header, args_str, 0);
+ va_list args_list;
+ va_start(args_list, first);
+
+ uchar* args_str = vstrjoin(first, args_list);
+ uchar* query_str = ustrjoin(header, args_str, NULL);
+ va_end(args_list);
+
assert(p);
assert(query_str);