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

Change dev->bcache_fd default value from 0 to -1

This fix can avoid bcache_fd will mistakenly open/close in later.

Signed-off-by: Zhao Heming <heming.zhao@suse.com>
This commit is contained in:
Zhao Heming 2020-06-01 12:22:15 -05:00 committed by David Teigland
parent d14a8040d4
commit b59127a838

View File

@ -65,6 +65,7 @@ static int _insert(const char *path, const struct stat *info,
static void _dev_init(struct device *dev)
{
dev->fd = -1;
dev->bcache_fd = -1;
dev->read_ahead = -1;
dev->ext.enabled = 0;