diff options
Diffstat (limited to 'perl-install/standalone')
-rwxr-xr-x | perl-install/standalone/drakboot | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/perl-install/standalone/drakboot b/perl-install/standalone/drakboot index f85dc9ec3..a2d8f6b15 100755 --- a/perl-install/standalone/drakboot +++ b/perl-install/standalone/drakboot @@ -80,7 +80,14 @@ unless ($::isEmbedded) { my @users = sort(list_users()); my @sessions = sort(split(' ', `/usr/sbin/chksession -l`)); -my $user_combo = Gtk2::ComboBox->new_with_strings(\@users, if_(member($auto_mode->{autologin}, @users), $auto_mode->{autologin})); + +my $user = member($auto_mode->{autologin}, @users) ? $auto_mode->{autologin} : $users[0]; +if (!$user) { + # no user, bad but add root anyway: + $user = "root"; + push @users, $user; +} +my $user_combo = Gtk2::ComboBox->new_with_strings(\@users, $user); my $desktop_combo = Gtk2::ComboBox->new_with_strings(\@sessions, if_(member($auto_mode->{desktop}, @sessions), $auto_mode->{desktop})); my %themes = ('path' => '/usr/share/bootsplash/themes/', |