From c3b550478adcf8fc6d8163f2f33afb7aa7f7e829 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 27 Feb 2020 16:23:12 +0100 Subject: [PATCH] pod: document that the choice array might have excess elements The choice array might have excess elements when the type has been changed, for example by fixation. This is not a problem and the excess elements should simply be ignored. --- spa/include/spa/pod/pod.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spa/include/spa/pod/pod.h b/spa/include/spa/pod/pod.h index dc07f823f..58ad38557 100644 --- a/spa/include/spa/pod/pod.h +++ b/spa/include/spa/pod/pod.h @@ -144,7 +144,8 @@ struct spa_pod_choice_body { uint32_t type; /**< type of choice, one of enum spa_choice_type */ uint32_t flags; /**< extra flags */ struct spa_pod child; - /* array with elements of child.size follows */ + /* array with elements of child.size follows. Note that there might be more + * elements than required by \a type, which should be ignored. */ }; struct spa_pod_choice {