From: Michael Wallner Date: Tue, 13 Oct 2020 06:43:12 +0000 (+0200) Subject: fix warning (double promotion) X-Git-Tag: 1.1.0-beta1~236^2~9 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=04e64c9f685ccf00e11238b0e19dc722f8630233;p=awesomized%2Flibmemcached fix warning (double promotion) --- diff --git a/src/libmemcached/hosts.cc b/src/libmemcached/hosts.cc index ab58c922..b8292b2b 100644 --- a/src/libmemcached/hosts.cc +++ b/src/libmemcached/hosts.cc @@ -232,7 +232,7 @@ static memcached_return_t update_continuum(Memcached *ptr) if (memcached_is_weighted_ketama(ptr)) { float pct= (float)list[host_index].weight / (float)total_weight; - pointer_per_server= (uint32_t) ((::floor((float) (pct * MEMCACHED_POINTS_PER_SERVER_KETAMA / 4 * (float)live_servers + 0.0000000001))) * 4); + pointer_per_server= (uint32_t) ((::floor((float) (pct * MEMCACHED_POINTS_PER_SERVER_KETAMA / 4 * (float)live_servers + 0.0000000001F))) * 4); pointer_per_hash= 4; if (0 && DEBUG) {