summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-04-12 02:40:42 +0000
committerDavid Robillard <d@drobilla.net>2012-04-12 02:40:42 +0000
commitf3b37538c6355ca2f878dafeaf322312dd742e59 (patch)
treedee28eb0332056a4f9fe27ff2b6715127e9f7bdc /src
parent9b3c2ddf33b0f9461643d7b7fa39e5e8668e77a2 (diff)
downloadsratom-f3b37538c6355ca2f878dafeaf322312dd742e59.tar.gz
sratom-f3b37538c6355ca2f878dafeaf322312dd742e59.tar.bz2
sratom-f3b37538c6355ca2f878dafeaf322312dd742e59.zip
Update for latest atom extension.
git-svn-id: http://svn.drobilla.net/lad/trunk/sratom@4172 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r--src/sratom.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/sratom.c b/src/sratom.c
index 9c4ace0..4caf14b 100644
--- a/src/sratom.c
+++ b/src/sratom.c
@@ -321,7 +321,7 @@ sratom_write(Sratom* sratom,
start_object(sratom, flags, subject, predicate, &id, type);
SerdNode p = serd_node_from_string(SERD_URI, NS_RDF "value");
flags |= SERD_LIST_O_BEGIN;
- LV2_TUPLE_BODY_FOREACH(body, size, i) {
+ LV2_ATOM_TUPLE_BODY_FOREACH(body, size, i) {
list_append(sratom, unmap, &flags, &id, &p, &node,
i->size, i->type, LV2_ATOM_BODY(i));
}
@@ -355,10 +355,9 @@ sratom_write(Sratom* sratom,
obj->otype);
gensym(&id, 'b', sratom->next_id++);
start_object(sratom, flags, subject, predicate, &id, otype);
- LV2_OBJECT_BODY_FOREACH(obj, size, i) {
- const LV2_Atom_Property_Body* prop = lv2_object_iter_get(i);
- const char* const key = unmap->unmap(unmap->handle, prop->key);
- SerdNode pred = serd_node_from_string(SERD_URI, USTR(key));
+ LV2_ATOM_OBJECT_BODY_FOREACH(obj, size, prop) {
+ const char* const key = unmap->unmap(unmap->handle, prop->key);
+ SerdNode pred = serd_node_from_string(SERD_URI, USTR(key));
sratom_write(sratom, unmap, flags|SERD_ANON_CONT, &id, &pred,
prop->value.type, prop->value.size,
LV2_ATOM_BODY(&prop->value));
@@ -372,8 +371,7 @@ sratom_write(Sratom* sratom,
start_object(sratom, flags, subject, predicate, &id, type);
SerdNode p = serd_node_from_string(SERD_URI, NS_RDF "value");
flags |= SERD_LIST_O_BEGIN;
- LV2_SEQUENCE_BODY_FOREACH(seq, size, i) {
- LV2_Atom_Event* ev = lv2_sequence_iter_get(i);
+ LV2_ATOM_SEQUENCE_BODY_FOREACH(seq, size, ev) {
list_append(sratom, unmap, &flags, &id, &p, &node,
sizeof(LV2_Atom_Event) + ev->body.size,
sratom->atom_Event,