mirror of
https://github.com/sheumann/hush.git
synced 2025-01-03 00:31:16 +00:00
Make init compile when DEBUG_INIT is enabled
-Erik
This commit is contained in:
parent
7e9276b50a
commit
dbcd8ce464
5
init.c
5
init.c
@ -459,9 +459,8 @@ static pid_t run(char *command, char *terminal, int get_enter)
|
|||||||
* specifies.
|
* specifies.
|
||||||
*/
|
*/
|
||||||
#ifdef DEBUG_INIT
|
#ifdef DEBUG_INIT
|
||||||
pid_t shell_pgid = getpid();
|
|
||||||
message(LOG, "Waiting for enter to start '%s' (pid %d, console %s)\r\n",
|
message(LOG, "Waiting for enter to start '%s' (pid %d, console %s)\r\n",
|
||||||
command, shell_pgid, terminal);
|
command, getpid(), terminal);
|
||||||
#endif
|
#endif
|
||||||
write(fileno(stdout), press_enter, sizeof(press_enter) - 1);
|
write(fileno(stdout), press_enter, sizeof(press_enter) - 1);
|
||||||
getc(stdin);
|
getc(stdin);
|
||||||
@ -470,7 +469,7 @@ static pid_t run(char *command, char *terminal, int get_enter)
|
|||||||
#ifdef DEBUG_INIT
|
#ifdef DEBUG_INIT
|
||||||
/* Log the process name and args */
|
/* Log the process name and args */
|
||||||
message(LOG, "Starting pid %d, console %s: '%s'\r\n",
|
message(LOG, "Starting pid %d, console %s: '%s'\r\n",
|
||||||
shell_pgid, terminal, command);
|
getpid(), terminal, command);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* See if any special /bin/sh requiring characters are present */
|
/* See if any special /bin/sh requiring characters are present */
|
||||||
|
@ -459,9 +459,8 @@ static pid_t run(char *command, char *terminal, int get_enter)
|
|||||||
* specifies.
|
* specifies.
|
||||||
*/
|
*/
|
||||||
#ifdef DEBUG_INIT
|
#ifdef DEBUG_INIT
|
||||||
pid_t shell_pgid = getpid();
|
|
||||||
message(LOG, "Waiting for enter to start '%s' (pid %d, console %s)\r\n",
|
message(LOG, "Waiting for enter to start '%s' (pid %d, console %s)\r\n",
|
||||||
command, shell_pgid, terminal);
|
command, getpid(), terminal);
|
||||||
#endif
|
#endif
|
||||||
write(fileno(stdout), press_enter, sizeof(press_enter) - 1);
|
write(fileno(stdout), press_enter, sizeof(press_enter) - 1);
|
||||||
getc(stdin);
|
getc(stdin);
|
||||||
@ -470,7 +469,7 @@ static pid_t run(char *command, char *terminal, int get_enter)
|
|||||||
#ifdef DEBUG_INIT
|
#ifdef DEBUG_INIT
|
||||||
/* Log the process name and args */
|
/* Log the process name and args */
|
||||||
message(LOG, "Starting pid %d, console %s: '%s'\r\n",
|
message(LOG, "Starting pid %d, console %s: '%s'\r\n",
|
||||||
shell_pgid, terminal, command);
|
getpid(), terminal, command);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* See if any special /bin/sh requiring characters are present */
|
/* See if any special /bin/sh requiring characters are present */
|
||||||
|
Loading…
Reference in New Issue
Block a user