Remove dead variable assignments

Found by:	clang static analyzer
Verified by:	md5(1)
This commit is contained in:
Ulrich Spörlein 2010-06-11 17:03:04 +00:00
parent ee4912eb07
commit 3ba5db25bb
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=209052
3 changed files with 2 additions and 4 deletions

View File

@ -177,11 +177,10 @@ do_single(int argc, char **argv, int action)
*/
if (action == CCD_UNCONFIG || action == CCD_UNCONFIGALL) {
ex = 0;
for (i = 0; argc != 0; ) {
for (; argc != 0;) {
cp = *argv++; --argc;
if ((ccd = resolve_ccdname(cp)) < 0) {
warnx("invalid ccd name: %s", cp);
i = 1;
continue;
}
grq = gctl_get_handle();

View File

@ -750,7 +750,7 @@ main(int argc, char **argv)
if (argc < 3)
usage();
if ((i = modfind("g_bde")) < 0) {
if (modfind("g_bde") < 0) {
/* need to load the gbde module */
if (kldload(GBDEMOD) < 0 || modfind("g_bde") < 0)
err(1, GBDEMOD ": Kernel module not available");

View File

@ -249,7 +249,6 @@ getConfig(FILE *fd, char *key, char **Ar, int *nargs)
switch(state) {
case 0:
if((p = strchr(lp, '{')) != NULL) {
n = 0;
while((--p > lp) && *p && isspace(*p));
n = p - lp;
if(len && strncmp(lp, key, MAX(n, len)) == 0)