1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-30 17:18:21 +03:00

gcc: same signess

This commit is contained in:
Zdenek Kabelac 2024-05-14 15:36:34 +02:00
parent 7d22be22d9
commit e3dff2cba2
4 changed files with 7 additions and 7 deletions

View File

@ -233,7 +233,7 @@ static int _sectors_to_units(uint64_t sectors, char *buffer, size_t s)
"Exabytes",
};
int i;
unsigned i;
double d = (double) sectors;
/* to convert to K */

View File

@ -364,7 +364,7 @@ static int _memlock_maps(struct cmd_context *cmd, lvmlock_t lock, size_t *mstats
for (len = 0 ; len < _maps_len; len += n) {
if (!(n = read(_maps_fd, _maps_buffer + len, _maps_len - len)))
break; /* EOF */
if ((n < 0) || (len >= (SSIZE_MAX - n))) {
if ((n < 0) || (len >= (size_t)(SSIZE_MAX - n))) {
log_sys_debug("read", _procselfmaps);
return 0;
}

View File

@ -583,7 +583,7 @@ static int _match_time_str(struct dm_list *ti_list, struct time_item *ti)
{
struct time_item *ti_context_p = (struct time_item *) dm_list_prev(ti_list, &ti->list);
size_t reg_len;
int i;
unsigned i;
ti->prop = TIME_PROP(TIME_NULL);

View File

@ -1661,7 +1661,7 @@ static int _udevflags(CMD_ARGS)
{
uint32_t cookie;
uint16_t flags;
int i;
unsigned i;
static const char _dm_flag_names[][32] = {
"DISABLE_DM_RULES",
"DISABLE_SUBSYSTEM_RULES",
@ -6318,7 +6318,7 @@ static void _devmap_name_usage(FILE *out)
static void _stats_usage(FILE *out)
{
int i;
unsigned i;
fprintf(out, "Usage:\n\n"
"%s\n\t"
@ -6342,7 +6342,7 @@ static void _stats_usage(FILE *out)
static void _dmsetup_usage(FILE *out)
{
int i;
unsigned i;
fprintf(out, "Usage:\n\n"
"%s\n\t"
@ -6453,7 +6453,7 @@ static int _dmsetup_help(CMD_ARGS)
static const struct command *_find_command(const struct command *commands,
size_t cmd_cnt, const char *name)
{
int i;
unsigned i;
if (name)
for (i = 0; i < cmd_cnt; i++)