From 5ab8e2cdfcdfb932b918405061798e0079223273 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Thu, 17 Dec 2015 14:13:22 +0100 Subject: stats: Fix compiler warning about losing const MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit stats_statsd.c: In function ‘osmo_stats_reporter_statsd_send_item’: stats_statsd.c:154:15: warning: initialization discards ‘const’ qualifier from pointer target type char *unit = desc->unit; ^ --- src/stats_statsd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/stats_statsd.c b/src/stats_statsd.c index b93d90a7..28134109 100644 --- a/src/stats_statsd.c +++ b/src/stats_statsd.c @@ -151,7 +151,7 @@ static int osmo_stats_reporter_statsd_send_item(struct osmo_stats_reporter *srep const struct osmo_stat_item_group *statg, const struct osmo_stat_item_desc *desc, int value) { - char *unit = desc->unit; + const char *unit = desc->unit; if (unit == OSMO_STAT_ITEM_NO_UNIT) { unit = "g"; -- cgit v1.2.3