mirror of
https://gitlab.freedesktop.org/plymouth/plymouth.git
synced 2026-05-08 14:48:01 +02:00
main: Fix parsing of plymouth.debug=stream: argument.
It did not terminate at space so the log file to use was not properly defined and any additional kernel command line args were added to the end of the file name.
This commit is contained in:
parent
3f0cf34885
commit
b8f2e2b11f
1 changed files with 7 additions and 0 deletions
|
|
@ -1797,6 +1797,12 @@ check_verbosity (state_t *state)
|
|||
|
||||
if (stream != NULL)
|
||||
{
|
||||
char *end;
|
||||
|
||||
stream = strdup (stream);
|
||||
end = stream + strcspn (stream, " \n");
|
||||
*end = '\0';
|
||||
|
||||
ply_trace ("streaming debug output to %s instead of screen", stream);
|
||||
fd = open (stream, O_RDWR | O_NOCTTY | O_CREAT, 0600);
|
||||
|
||||
|
|
@ -1808,6 +1814,7 @@ check_verbosity (state_t *state)
|
|||
{
|
||||
ply_logger_set_output_fd (ply_logger_get_error_default (), fd);
|
||||
}
|
||||
free (stream);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue