1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-05 13:18:20 +03:00

cov: mask uninitialized value

Coverity doesn't track ioctl() too well, so let's just make it quiet.
This commit is contained in:
Zdenek Kabelac 2021-03-09 15:58:48 +01:00
parent 74936f53f7
commit bee9b5c1d8
5 changed files with 5 additions and 5 deletions

View File

@ -1224,7 +1224,7 @@ int get_dev_node_read_ahead(const char *dev_name, uint32_t major, uint32_t minor
int len;
int r = 1;
int fd;
long read_ahead_long;
long read_ahead_long = 0;
/*
* If we know the device number, use sysfs if we can.

View File

@ -81,7 +81,7 @@ typedef struct dasd_information2_t {
int dasd_is_cdl_formatted(struct device *dev)
{
int ret = 0;
dasd_information2_t dasd_info2;
dasd_information2_t dasd_info2 = { 0 };
if (!dev_open_readonly(dev))
return_0;

View File

@ -124,7 +124,7 @@ static int _dev_get_size_dev(struct device *dev, uint64_t *size)
static int _dev_read_ahead_dev(struct device *dev, uint32_t *read_ahead)
{
long read_ahead_long;
long read_ahead_long = 0;
if (dev->read_ahead != -1) {
*read_ahead = (uint32_t) dev->read_ahead;

View File

@ -891,7 +891,7 @@ static int _wipe_signature(struct device *dev, const char *type, const char *nam
int (*signature_detection_fn)(struct device *dev, uint64_t *offset_found, int full))
{
int wipe;
uint64_t offset_found;
uint64_t offset_found = 0;
wipe = signature_detection_fn(dev, &offset_found, 1);
if (wipe == -1) {

View File

@ -1222,7 +1222,7 @@ int get_dev_node_read_ahead(const char *dev_name, uint32_t major, uint32_t minor
int len;
int r = 1;
int fd;
long read_ahead_long;
long read_ahead_long = 0;
/*
* If we know the device number, use sysfs if we can.