From 59141f62bb2263b95772e5bc22151bd91a2e148a Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 22 Jun 2016 12:24:55 +0200 Subject: [PATCH] filter/route: use std::array --- src/filter/plugins/RouteFilterPlugin.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/filter/plugins/RouteFilterPlugin.cxx b/src/filter/plugins/RouteFilterPlugin.cxx index 450b01f12..0f061e597 100644 --- a/src/filter/plugins/RouteFilterPlugin.cxx +++ b/src/filter/plugins/RouteFilterPlugin.cxx @@ -52,6 +52,7 @@ #include "util/ConstBuffer.hxx" #include +#include #include #include @@ -78,7 +79,7 @@ class RouteFilter final : public Filter { * a corresponding input channel from which to take the * data. A -1 means "no source" */ - int8_t sources[MAX_CHANNELS]; + std::array sources; /** * The actual input format of our signal, once opened @@ -135,7 +136,7 @@ RouteFilter::Configure(const ConfigBlock &block, Error &error) { * dynamic realloc() instead of one count run and one malloc(). */ - std::fill_n(sources, MAX_CHANNELS, -1); + sources.fill(-1); min_input_channels = 0; min_output_channels = 0;