if (!pid) {
if(!strncmp(pr->type, "f2fs", 4)) {
execl(ckfs, ckfs, "-f", pr->dev, NULL);
- exit(-1);
+ exit(EXIT_FAILURE);
} else if(!strncmp(pr->type, "btrfs", 5)) {
execl(ckfs, ckfs, "--repair", pr->dev, NULL);
- exit(-1);
+ exit(EXIT_FAILURE);
} else if(!strncmp(pr->type, "ntfs", 4)) {
execl(ckfs, ckfs, "-b", pr->dev, NULL);
- exit(-1);
+ exit(EXIT_FAILURE);
} else {
execl(ckfs, ckfs, "-p", pr->dev, NULL);
- exit(-1);
+ exit(EXIT_FAILURE);
}
} else if (pid > 0) {
int status;
argv[a++] = device;
execvp(argv[0], argv);
ULOG_ERR("failed to spawn %s %s %s\n", *argv, action, device);
- exit(-1);
+ exit(EXIT_FAILURE);
default:
waitpid(pid, &status, 0);
if (kproto_version != 5) {
ULOG_ERR("only kernel protocol version 5 is tested. You have %d.\n",
kproto_version);
- exit(1);
+ exit(EXIT_FAILURE);
}
if (ioctl(fd_autofs_write, AUTOFS_IOC_SETTIMEOUT, &autofs_timeout))
ULOG_ERR("failed to set autofs timeout\n");