From a179e0fecd341857e61ea02f303c1eb2ee5233e5 Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Fri, 4 Jun 2021 13:45:52 +1000 Subject: [PATCH] spa: fix a C++ typecast warning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit void* cannot be automatically type-casted so let's do this explicitly. ../spa/include/spa/param/latency-utils.h: In function ‘spa_pod* spa_latency_build(spa_pod_builder*, uint32_t, const spa_latency_info*)’: ../spa/include/spa/pod/builder.h:651:1: error: invalid conversion from ‘void*’ to ‘spa_pod*’ [-fpermissive] --- spa/include/spa/param/latency-utils.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spa/include/spa/param/latency-utils.h b/spa/include/spa/param/latency-utils.h index 2a65a5469..d6b025200 100644 --- a/spa/include/spa/param/latency-utils.h +++ b/spa/include/spa/param/latency-utils.h @@ -99,7 +99,7 @@ spa_latency_parse(const struct spa_pod *latency, struct spa_latency_info *info) static inline struct spa_pod * spa_latency_build(struct spa_pod_builder *builder, uint32_t id, const struct spa_latency_info *info) { - return spa_pod_builder_add_object(builder, + return (struct spa_pod *)spa_pod_builder_add_object(builder, SPA_TYPE_OBJECT_ParamLatency, id, SPA_PARAM_LATENCY_direction, SPA_POD_Id(info->direction), SPA_PARAM_LATENCY_minQuantum, SPA_POD_Float(info->min_quantum),