]> git.pld-linux.org Git - packages/SysVinit.git/blob - sysvinit-quiet.patch
- updated to 3.04
[packages/SysVinit.git] / sysvinit-quiet.patch
1 diff -urNp -x '*.orig' sysvinit-2.99.org/src/init.c sysvinit-2.99/src/init.c
2 --- sysvinit-2.99.org/src/init.c        2021-02-25 08:11:43.504364931 +0100
3 +++ sysvinit-2.99/src/init.c    2021-02-25 08:11:43.584367421 +0100
4 @@ -153,6 +153,7 @@ struct utmp utproto;                /* Only used for s
5  char *console_dev;             /* Console device. */
6  int pipe_fd = -1;              /* /run/initctl */
7  int did_boot = 0;              /* Did we already do BOOT* stuff? */
8 +int quiet = 0;                 /* Should we be relatively silent? */
9  int main(int, char **);
10  
11  /*     Used by re-exec part */
12 @@ -2069,7 +2070,7 @@ int read_level(int arg)
13                         initlog(L_SY, "Trying to re-exec init");
14                         return 'U';
15                 default:
16 -                       initlog(L_VB, "Switching to runlevel: %c", foo);
17 +                       if (!quiet) initlog(L_VB, "Switching to runlevel: %c", foo);
18         }
19  
20         if (foo == 'Q') {
21 @@ -2893,7 +2894,7 @@ void init_main(void)
22         /*
23          *      Say hello to the world
24          */
25 -       initlog(L_CO, bootmsg, "booting");
26 +       if (!quiet) initlog(L_CO, bootmsg, "booting");
27  
28         /*
29          *      See if we have to start an emergency shell.
30 @@ -3162,6 +3163,8 @@ int main(int argc, char **argv)
31                 else if (!strcmp(argv[f], "-z")) {
32                         /* Ignore -z xxx */
33                         if (argv[f + 1]) f++;
34 +               } else if (!strcmp(argv[f], "quiet")) {
35 +                       quiet = 1;
36                 } else if (strchr("0123456789sS", argv[f][0])
37                         && strlen(argv[f]) == 1)
38                         dfl_level = argv[f][0];
This page took 0.028216 seconds and 3 git commands to generate.