summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src
diff options
context:
space:
mode:
authorIraj Jamali <ijamali@redhat.com>2018-12-17 11:23:59 +0530
committerAmar Tumballi <amarts@redhat.com>2019-01-11 18:25:18 +0000
commit01779e6c6c2c876a9e137d51ee1ce6a8062ea893 (patch)
tree8738a794b0ed38b84f99bc11d1442d1464a5b5fe /libglusterfs/src
parentc0c2022e7d7097e96270a74f37813eda0c4e6339 (diff)
fix 32-bit-build-smoke warnings
fixes: bz#1622665 Change-Id: I777d67b1b62c284c62a02277238ad7538eef001e Signed-off-by: Iraj Jamali <ijamali@redhat.com>
Diffstat (limited to 'libglusterfs/src')
-rw-r--r--libglusterfs/src/common-utils.c2
-rw-r--r--libglusterfs/src/inode.c2
-rw-r--r--libglusterfs/src/statedump.c12
3 files changed, 8 insertions, 8 deletions
diff --git a/libglusterfs/src/common-utils.c b/libglusterfs/src/common-utils.c
index b8c3e2de126..6cefb2a439b 100644
--- a/libglusterfs/src/common-utils.c
+++ b/libglusterfs/src/common-utils.c
@@ -1702,7 +1702,7 @@ gf_uint64_2human_readable(uint64_t n)
if (ret < 0)
goto err;
} else {
- ret = gf_asprintf(&str, "%luBytes", n);
+ ret = gf_asprintf(&str, "%" PRIu64 "Bytes", n);
if (ret < 0)
goto err;
}
diff --git a/libglusterfs/src/inode.c b/libglusterfs/src/inode.c
index b4a62897498..87f74e09f1d 100644
--- a/libglusterfs/src/inode.c
+++ b/libglusterfs/src/inode.c
@@ -2456,7 +2456,7 @@ inode_dump(inode_t *inode, char *prefix)
{
nlookup = GF_ATOMIC_GET(inode->nlookup);
gf_proc_dump_write("gfid", "%s", uuid_utoa(inode->gfid));
- gf_proc_dump_write("nlookup", "%ld", nlookup);
+ gf_proc_dump_write("nlookup", "%" PRIu64, nlookup);
gf_proc_dump_write("fd-count", "%u", inode->fd_count);
gf_proc_dump_write("active-fd-count", "%u", inode->active_fd_count);
gf_proc_dump_write("ref", "%u", inode->ref);
diff --git a/libglusterfs/src/statedump.c b/libglusterfs/src/statedump.c
index 690b13088f1..d18b50facf4 100644
--- a/libglusterfs/src/statedump.c
+++ b/libglusterfs/src/statedump.c
@@ -383,7 +383,7 @@ gf_proc_dump_mempool_info(glusterfs_ctx_t *ctx)
gf_proc_dump_write("sizeof-type", "%lu", pool->sizeof_type);
gf_proc_dump_write("padded-sizeof", "%d",
1 << pool->pool->power_of_two);
- gf_proc_dump_write("size", "%lu",
+ gf_proc_dump_write("size", "%" PRId64,
(1 << pool->pool->power_of_two) * active);
gf_proc_dump_write("shared-pool", "%p", pool->pool);
}
@@ -461,17 +461,17 @@ gf_proc_dump_latency_info(xlator_t *xl);
void
gf_proc_dump_dict_info(glusterfs_ctx_t *ctx)
{
- uint64_t total_dicts = 0;
- uint64_t total_pairs = 0;
+ int64_t total_dicts = 0;
+ int64_t total_pairs = 0;
total_dicts = GF_ATOMIC_GET(ctx->stats.total_dicts_used);
total_pairs = GF_ATOMIC_GET(ctx->stats.total_pairs_used);
gf_proc_dump_write("max-pairs-per-dict", "%" GF_PRI_ATOMIC,
GF_ATOMIC_GET(ctx->stats.max_dict_pairs));
- gf_proc_dump_write("total-pairs-used", "%lu", total_pairs);
- gf_proc_dump_write("total-dicts-used", "%lu", total_dicts);
- gf_proc_dump_write("average-pairs-per-dict", "%lu",
+ gf_proc_dump_write("total-pairs-used", "%" PRId64, total_pairs);
+ gf_proc_dump_write("total-dicts-used", "%" PRId64, total_dicts);
+ gf_proc_dump_write("average-pairs-per-dict", "%" PRId64,
(total_pairs / total_dicts));
}