plymouth check for "splash" in cmdline incorrectly matches "nosplash" too

Bug #562278 reported by Craig Ringer
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
plymouth (Ubuntu)
New
Undecided
Unassigned

Bug Description

Binary package hint: plymouth

Distributor ID: Ubuntu
Description: Ubuntu lucid (development branch)
Release: 10.04
Codename: lucid

plymouth:
  Installed: 0.8.1-4ubuntu1
  Candidate: 0.8.1-4ubuntu1
  Version table:
 *** 0.8.1-4ubuntu1 0
        500 http://ftp.iinet.net.au/pub/ubuntu/ lucid/main Packages
        500 http://au.archive.ubuntu.com/ubuntu/ lucid/main Packages
        100 /var/lib/dpkg/status

Plymouth sees a kernel command line containing the text 'splash' anywhere in it as a request to show a splash screen. This includes a kernel command line containing "nosplash" or any other text with "splash" in it.

As "nosplash" used to be a way to get rid of the accursed splash screen back in the day, it's not unheard of to see it on kernel command lines.

The test in main.c:615 in the function plymouth_should_show_default_splash(state_t * state) reveals why.

  return strstr (state->kernel_command_line, "rhgb") != NULL ||
     (strstr (state->kernel_command_line, "splash") != NULL && strstr(state->kernel_command_line, "splash=verbose") == NULL);

the test for "splash" will match any substring. It should be checking for " splash" with a trailing space or end-of-string.

Removing "nosplash" from my kernel command line got rid of the splash screen :S

Revision history for this message
Craig Ringer (ringerc) wrote :

The attached patch adds a simple function that does a more robust check for a keyword in the kernel command line, and converts the problem function to use it.

Plymouth makes ... iffy ... keyword checks in many other places, and these should probably use the function as well. Pretty much anywhere state->kernel_command_line is referenced.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.