summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2019-06-21 21:18:43 +0200
committerDavid Robillard <d@drobilla.net>2019-06-21 21:18:43 +0200
commit1bce600a6f308b3bd836f85eb1cc62d3c93a5f35 (patch)
treea6b402cee803b8c246603e479c1a34d0d6be72a0 /test
parent6d0995694ca5a3de916cc9746f4104f066b22718 (diff)
downloadlilv-1bce600a6f308b3bd836f85eb1cc62d3c93a5f35.tar.gz
lilv-1bce600a6f308b3bd836f85eb1cc62d3c93a5f35.tar.bz2
lilv-1bce600a6f308b3bd836f85eb1cc62d3c93a5f35.zip
Refuse to store state properties with null keys
Diffstat (limited to 'test')
-rw-r--r--test/test.lv2/test.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/test.lv2/test.c b/test/test.lv2/test.c
index bf0f87b..c1cf4d7 100644
--- a/test/test.lv2/test.c
+++ b/test/test.lv2/test.c
@@ -213,6 +213,16 @@ save(LV2_Handle instance,
return LV2_STATE_ERR_UNKNOWN;
}
+ // Try to store with a null key (should fail)
+ if (!store(callback_data,
+ 0,
+ &urid2,
+ sizeof(uint32_t),
+ map_uri(plugin, LV2_ATOM__URID),
+ LV2_STATE_IS_POD | LV2_STATE_IS_PORTABLE)) {
+ return LV2_STATE_ERR_UNKNOWN;
+ }
+
store(callback_data,
map_uri(plugin, "http://example.org/num-runs"),
&plugin->num_runs,