From 76a4afec6e03d15cb442e819f6fe7b94d6f9f487 Mon Sep 17 00:00:00 2001 From: Pranith Kumar K Date: Tue, 6 Nov 2012 12:19:47 +0530 Subject: libglusterfs: Implement float percentage Change-Id: Ia7ea63471f0bbd74686873f5f6f183475880f1a0 BUG: 839595 Signed-off-by: Pranith Kumar K Reviewed-on: http://review.gluster.org/4162 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/cluster/dht/src/dht.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'xlators/cluster/dht/src/dht.c') diff --git a/xlators/cluster/dht/src/dht.c b/xlators/cluster/dht/src/dht.c index 80d00c96b55..d7b1e9655e7 100644 --- a/xlators/cluster/dht/src/dht.c +++ b/xlators/cluster/dht/src/dht.c @@ -125,8 +125,8 @@ dht_priv_dump (xlator_t *this) gf_proc_dump_write("search_unhashed", "%d", conf->search_unhashed); gf_proc_dump_write("gen", "%d", conf->gen); - gf_proc_dump_write("min_free_disk", "%lu", conf->min_free_disk); - gf_proc_dump_write("min_free_inodes", "%lu", conf->min_free_inodes); + gf_proc_dump_write("min_free_disk", "%lf", conf->min_free_disk); + gf_proc_dump_write("min_free_inodes", "%lf", conf->min_free_inodes); gf_proc_dump_write("disk_unit", "%c", conf->disk_unit); gf_proc_dump_write("refresh_interval", "%d", conf->refresh_interval); gf_proc_dump_write("unhashed_sticky_bit", "%d", conf->unhashed_sticky_bit); @@ -326,7 +326,7 @@ reconfigure (xlator_t *this, dict_t *options) percent_or_size, out); /* option can be any one of percent or bytes */ conf->disk_unit = 0; - if (conf->min_free_disk < 100) + if (conf->min_free_disk < 100.0) conf->disk_unit = 'p'; GF_OPTION_RECONF ("min-free-inodes", conf->min_free_inodes, options, -- cgit