1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

cleanup: use matching signed types

This commit is contained in:
Zdenek Kabelac 2013-11-25 13:42:30 +01:00
parent c6cfd7b2b9
commit 50e1fad86a
4 changed files with 6 additions and 6 deletions

View File

@ -1095,7 +1095,7 @@ static int verify_message(char *buf, int len)
{
struct clvm_header *h = (struct clvm_header *)buf;
if (len < sizeof(struct clvm_header)) {
if (len < (int)sizeof(struct clvm_header)) {
log_error("verify_message short len %d", len);
return -1;
}

View File

@ -847,7 +847,7 @@ static int _remove_mirror_images(struct logical_volume *lv,
uint32_t new_area_count = mirrored_seg->area_count;
struct lv_list *lvl;
struct dm_list tmp_orphan_lvs;
int orig_removed = num_removed;
uint32_t orig_removed = num_removed;
if (removed)
*removed = 0;

View File

@ -51,7 +51,7 @@ struct backend backend[] = {
void daemon_log(log_state *s, int type, const char *message) {
int i = 0;
while ( backend[i].id ) {
if ( (s->log_config[type] & backend[i].id) == backend[i].id )
if ((int)(s->log_config[type] & backend[i].id) == backend[i].id )
backend[i].log( s, &s->backend_state[i], type, message );
++ i;
}
@ -60,7 +60,7 @@ void daemon_log(log_state *s, int type, const char *message) {
static int _type_interesting(log_state *s, int type) {
int i = 0;
while ( backend[i].id ) {
if ( (s->log_config[type] & backend[i].id) == backend[i].id )
if ((int)(s->log_config[type] & backend[i].id) == backend[i].id )
return 1;
++ i;
}

View File

@ -958,7 +958,7 @@ static void _lvconvert_mirrors_repair_ask(struct cmd_context *cmd,
* 1 = 'disk'
* 2+ = 'mirrored'
*/
static int _get_log_count(struct logical_volume *lv)
static uint32_t _get_log_count(struct logical_volume *lv)
{
struct logical_volume *log_lv;
@ -1434,7 +1434,7 @@ int mirror_remove_missing(struct cmd_context *cmd,
if (!(failed_pvs = _failed_pv_list(lv->vg)))
return_0;
if (force && _failed_mirrors_count(lv) == lv_mirror_count(lv)) {
if (force && _failed_mirrors_count(lv) == (int)lv_mirror_count(lv)) {
log_error("No usable images left in %s.", lv->name);
return lv_remove_with_dependencies(cmd, lv, DONT_PROMPT, 0);
}