aboutsummaryrefslogtreecommitdiffstats
path: root/lv2/lv2plug.in/ns/ext/atom/util.h
diff options
context:
space:
mode:
Diffstat (limited to 'lv2/lv2plug.in/ns/ext/atom/util.h')
-rw-r--r--lv2/lv2plug.in/ns/ext/atom/util.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/lv2/lv2plug.in/ns/ext/atom/util.h b/lv2/lv2plug.in/ns/ext/atom/util.h
index f07956b..6ba178c 100644
--- a/lv2/lv2plug.in/ns/ext/atom/util.h
+++ b/lv2/lv2plug.in/ns/ext/atom/util.h
@@ -204,10 +204,11 @@ lv2_atom_object_is_end(const LV2_Atom_Object_Body* body,
static inline LV2_Atom_Property_Body*
lv2_atom_object_next(const LV2_Atom_Property_Body* i)
{
- const LV2_Atom* const value = (LV2_Atom*)((uint8_t*)i + sizeof(i));
- return (LV2_Atom_Property_Body*)((uint8_t*)i
- + sizeof(LV2_Atom_Property_Body)
- + lv2_atom_pad_size(value->size));
+ const LV2_Atom* const value = (LV2_Atom*)(
+ (uint8_t*)i + 2 * sizeof(uint32_t));
+ return (LV2_Atom_Property_Body*)(
+ (uint8_t*)i + lv2_atom_pad_size(sizeof(LV2_Atom_Property_Body)
+ + value->size));
}
/**