Radish alpha
H
rad:z3QDZAW2FAfuLvihrhiyDC9fAD8G9
HardenedBSD Package Manager
Radicle
Git
Improve style.
Vsevolod Stakhov committed 12 years ago
commit 3c474f3a16cb6610d2c39ff09900290acdaad7d4
parent b03f015
1 file changed +3 -8
modified src/which.c
@@ -45,7 +45,7 @@ usage_which(void)
	fprintf(stderr, "For more information see 'pkg help which'.\n");
}

-
static int is_there(char *);
+
static bool is_there(char *);
int get_match(char **, char *, char *);

int
@@ -194,15 +194,10 @@ exec_which(int argc, char **argv)
}


-
static int
+
static bool
is_there(char *candidate)
{
-
	struct stat fin;
-

-
	if (access(candidate, F_OK) == 0) {
-
		return (1);
-
	}
-
	return (0);
+
	return (access(candidate, F_OK) == 0);
}

int