diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2017-03-09 23:41:54 +0100 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2017-03-10 19:33:01 +0100 |
commit | a11b875074936fa7ae357133f1e2e3f18ebdc3eb (patch) | |
tree | 03bbd27700ae7e2c4438ad65ee5013bbfa6c9465 /libdm/libdm-targets.c | |
parent | d11b8eef893b9bd05b2e923f8637e527df16ac01 (diff) | |
download | lvm2-a11b875074936fa7ae357133f1e2e3f18ebdc3eb.tar.gz |
cleanup: use FMTu
Replace some PRIu with FMTu for formating strings.
Diffstat (limited to 'libdm/libdm-targets.c')
-rw-r--r-- | libdm/libdm-targets.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/libdm/libdm-targets.c b/libdm/libdm-targets.c index f44abfd53..1709c2b2c 100644 --- a/libdm/libdm-targets.c +++ b/libdm/libdm-targets.c @@ -119,7 +119,7 @@ int dm_get_status_raid(struct dm_pool *mem, const char *params, goto_bad; msg_fields = "<raid_type> <#devices> <health_chars> and <sync_ratio> "; - if (sscanf(params, "%s %u %s %" PRIu64 "/%" PRIu64, + if (sscanf(params, "%s %u %s " FMTu64 "/" FMTu64, s->raid_type, &s->dev_count, s->dev_health, @@ -146,7 +146,7 @@ int dm_get_status_raid(struct dm_pool *mem, const char *params, if (!(s->sync_action = dm_pool_zalloc(mem, pp - p))) goto_bad; - if (sscanf(p, "%s %" PRIu64, s->sync_action, &s->mismatch_count) != 2) + if (sscanf(p, "%s " FMTu64, s->sync_action, &s->mismatch_count) != 2) goto_bad; if (num_fields < 7) @@ -162,7 +162,7 @@ int dm_get_status_raid(struct dm_pool *mem, const char *params, msg_fields = "<data_offset>"; if (!(p = _skip_fields(params, 6))) /* skip pre-1.9.0 params */ goto bad; - if (sscanf(p, "%" PRIu64, &s->data_offset) != 1) + if (sscanf(p, FMTu64, &s->data_offset) != 1) goto bad; out: @@ -244,14 +244,14 @@ int dm_get_status_cache(struct dm_pool *mem, const char *params, /* Read in args that have definitive placement */ if (sscanf(params, - " %" PRIu32 - " %" PRIu64 "/%" PRIu64 - " %" PRIu32 - " %" PRIu64 "/%" PRIu64 - " %" PRIu64 " %" PRIu64 - " %" PRIu64 " %" PRIu64 - " %" PRIu64 " %" PRIu64 - " %" PRIu64 + " " FMTu32 + " " FMTu64 "/" FMTu64 + " " FMTu32 + " " FMTu64 "/" FMTu64 + " " FMTu64 " " FMTu64 + " " FMTu64 " " FMTu64 + " " FMTu64 " " FMTu64 + " " FMTu64 " %d", &s->metadata_block_size, &s->metadata_used_blocks, &s->metadata_total_blocks, |