mirror of
https://github.com/troglobit/finit.git
synced 2026-10-24 11:54:36 +00:00
Merge branch 'master' of claudio@git.mandriva.com:/people/blino/finit
This commit is contained in:
commit
ead2eb7076
2 files changed
+4
-16
No files matched your search
+3
-16
@@ -182,8 +182,6 @@ int main()
|
|||||||
FILE *f;
|
FILE *f;
|
||||||
char line[LINE_SIZE];
|
char line[LINE_SIZE];
|
||||||
int fd;
|
int fd;
|
||||||
DIR *dir;
|
|
||||||
struct dirent *d;
|
|
||||||
struct sigaction sa, act;
|
struct sigaction sa, act;
|
||||||
sigset_t nmask, nmask2;
|
sigset_t nmask, nmask2;
|
||||||
char username[USERNAME_SIZE] = DEFUSER;
|
char username[USERNAME_SIZE] = DEFUSER;
|
||||||
@@ -312,6 +310,7 @@ int main()
|
|||||||
chardev("/dev/urandom", 0666, 1, 9);
|
chardev("/dev/urandom", 0666, 1, 9);
|
||||||
chardev("/dev/ptmx", 0666, 5, 2);
|
chardev("/dev/ptmx", 0666, 5, 2);
|
||||||
chardev("/dev/null", 0666, 1, 3);
|
chardev("/dev/null", 0666, 1, 3);
|
||||||
|
chmod("/dev/null", 0666);
|
||||||
chardev("/dev/mem", 0640, 1, 1);
|
chardev("/dev/mem", 0640, 1, 1);
|
||||||
chardev("/dev/tty0", 0660, 4, 0);
|
chardev("/dev/tty0", 0660, 4, 0);
|
||||||
chardev("/dev/input/mice", 0660, 13, 63);
|
chardev("/dev/input/mice", 0660, 13, 63);
|
||||||
@@ -339,20 +338,8 @@ int main()
|
|||||||
/*
|
/*
|
||||||
* Network stuff
|
* Network stuff
|
||||||
*/
|
*/
|
||||||
makepath("/dev/shm/network");
|
makepath("/var/run/resolvconf/interface");
|
||||||
makepath("/dev/shm/resolvconf/interface");
|
symlink("../../../etc/resolv.conf", "/var/run/resolvconf/resolv.conf");
|
||||||
|
|
||||||
if ((dir = opendir("/etc/resolvconf/run/interface")) != NULL) {
|
|
||||||
while ((d = readdir(dir)) != NULL) {
|
|
||||||
if (isalnum(d->d_name[0]))
|
|
||||||
continue;
|
|
||||||
snprintf(line, LINE_SIZE,
|
|
||||||
"/etc/resolvconf/run/interface/%s", d->d_name);
|
|
||||||
unlink(line);
|
|
||||||
}
|
|
||||||
|
|
||||||
closedir(dir);
|
|
||||||
}
|
|
||||||
|
|
||||||
touch("/var/run/utmp");
|
touch("/var/run/utmp");
|
||||||
chown("/var/run/utmp", 0, getgroup("utmp"));
|
chown("/var/run/utmp", 0, getgroup("utmp"));
|
||||||
|
|||||||
Reference in new issue
Block a user