1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00
lvm2/daemons
Peter Rajnoha eccc97f15a coverity: remove redundant condition
LVM2.2.02.112/daemons/clvmd/clvmd.c:1131: warning[arrayIndexOutOfBoundsCond]: Array 'row[8]' accessed at index 8, which is out of bounds. Otherwise condition 'j==8' is redundant.

This code:

int i,j = 0;
...
for (i = 0; i < len; ++i) {
	...
	if ((j == 8) || (i + 1 == len)) {
		for (;j < 8; ++j) {
			...
		}
		...
		j = 0;
	}
}

Indeed - j is 0 at the beginning, then iterating till j < 8,
then always zeroed at the end of the outer loop - so "j" never
reaching value of 8 - the j == 8 condition is redundant.
2014-11-12 09:30:02 +01:00
..
clvmd coverity: remove redundant condition 2014-11-12 09:30:02 +01:00
cmirrord pre-release 2014-11-11 14:13:00 +00:00
dmeventd dmeventd: Add basic thread debugging messages. 2014-11-04 18:56:20 +00:00
lvmetad cleanup: gcc warnings 2014-11-10 22:05:49 +01:00
Makefile.in makefiles: move subdir into same section 2014-04-18 16:38:49 +02:00