diff options
| author | Ray Strode <rstrode@redhat.com> | 2008-05-28 15:41:27 -0400 |
|---|---|---|
| committer | Ray Strode <rstrode@redhat.com> | 2008-05-28 15:41:27 -0400 |
| commit | d469d3fd75189c709748a40765eee8bca12aa91c (patch) | |
| tree | b1e02ca672d669c53bc82ca3cc338993dea260d7 /src/splash-plugins | |
| parent | 7e0dee1af1d8502fd23cb32358ffab2b9b5655b5 (diff) | |
| download | plymouth-d469d3fd75189c709748a40765eee8bca12aa91c.tar.gz plymouth-d469d3fd75189c709748a40765eee8bca12aa91c.tar.xz plymouth-d469d3fd75189c709748a40765eee8bca12aa91c.zip | |
Don't crash if the user presses enter when a password isn't being asked for
Diffstat (limited to 'src/splash-plugins')
| -rw-r--r-- | src/splash-plugins/spinfinity/spinfinity.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/splash-plugins/spinfinity/spinfinity.c b/src/splash-plugins/spinfinity/spinfinity.c index 12534d4..f1e9c11 100644 --- a/src/splash-plugins/spinfinity/spinfinity.c +++ b/src/splash-plugins/spinfinity/spinfinity.c @@ -441,11 +441,19 @@ void on_enter (ply_boot_splash_plugin_t *plugin, const char *text) { + if (plugin->password_answer_handler == NULL) + return; + plugin->password_answer_handler (plugin->password_answer_data, text); - plugin->entry->number_of_bullets = 0; - entry_free (plugin->entry); - plugin->entry = NULL; + + if (plugin->entry != NULL) + { + plugin->entry->number_of_bullets = 0; + entry_free (plugin->entry); + plugin->entry = NULL; + } + start_animation (plugin); } |
