mirror of
https://github.com/systemd/systemd.git
synced 2025-04-01 18:50:16 +03:00
[PATCH] udevstart fixes
udevstart_no_retval: currently udevstart will always return rc=22 because of the error handling code. I completely removed it because it is not used, and returning a generic error to the init script is not much useful anyway.
This commit is contained in:
parent
824e601185
commit
3f20eac0a5
12
udevstart.c
12
udevstart.c
@ -78,12 +78,11 @@ static void udev_exec(const char *path, const char* subsystem)
|
||||
}
|
||||
}
|
||||
|
||||
static int udev_scan(void)
|
||||
static void udev_scan(void)
|
||||
{
|
||||
char *devpath;
|
||||
DIR *dir;
|
||||
struct dirent *dent;
|
||||
int retval = -EINVAL;
|
||||
|
||||
devpath = "block";
|
||||
dir = opendir(SYSBLOCK);
|
||||
@ -179,11 +178,6 @@ static int udev_scan(void)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (retval > 0)
|
||||
retval = 0;
|
||||
|
||||
return -retval;
|
||||
}
|
||||
|
||||
|
||||
@ -191,5 +185,7 @@ int main(int argc, char *argv[], char *envp[])
|
||||
{
|
||||
init_logging("udevstart");
|
||||
|
||||
return udev_scan();
|
||||
udev_scan();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user