[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[hurd] 48/53: Fix crash on opening /dev/kbd or mouse without any console
From: |
Samuel Thibault |
Subject: |
[hurd] 48/53: Fix crash on opening /dev/kbd or mouse without any console being active |
Date: |
Thu, 20 Mar 2014 02:23:53 +0000 |
This is an automated email from the git hooks/post-receive script.
sthibault pushed a commit to branch upstream
in repository hurd.
commit 4097daba7e43b3a1a3af77a715da1a2418d30392
Author: Samuel Thibault <address@hidden>
Date: Sun Mar 16 18:13:58 2014 +0100
Fix crash on opening /dev/kbd or mouse without any console being active
* console-client/console.c (console_switch_away): Check for `active_vcons`
being NULL before saving the currently active console.
---
console-client/console.c | 15 +++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/console-client/console.c b/console-client/console.c
index 2fb2fbe..2fa0533 100644
--- a/console-client/console.c
+++ b/console-client/console.c
@@ -226,10 +226,17 @@ console_switch_away (void)
if (driver->ops->save_status)
driver->ops->save_status (driver->handle);
- saved_id = active_vcons->id;
- saved_cons = active_vcons->cons;
- cons_vcons_close (active_vcons);
- active_vcons = NULL;
+ if (active_vcons)
+ {
+ saved_id = active_vcons->id;
+ saved_cons = active_vcons->cons;
+ cons_vcons_close (active_vcons);
+ active_vcons = NULL;
+ }
+ else
+ {
+ saved_cons = NULL;
+ }
pthread_mutex_unlock (&global_lock);
}
--
Alioth's /usr/local/bin/git-commit-notice on
/srv/git.debian.org/git/pkg-hurd/hurd.git
- [hurd] branch upstream updated (a3ffccc -> c6f5e3e), Samuel Thibault, 2014/03/19
- [hurd] 28/53: trans/mtab: do not map unknown source strings to "none", Samuel Thibault, 2014/03/19
- [hurd] 34/53: hurd: add IIOCTL_IMPORTS, Samuel Thibault, 2014/03/19
- [hurd] 48/53: Fix crash on opening /dev/kbd or mouse without any console being active,
Samuel Thibault <=
- [hurd] 44/53: mach-defpager: fix warning about uninitialized variable, Samuel Thibault, 2014/03/19
- [hurd] 38/53: trans/ifsock: fix receiver lookup, Samuel Thibault, 2014/03/19
- [hurd] 40/53: mach-defpager: remove comments around form feeds, Samuel Thibault, 2014/03/19
- [hurd] 45/53: mach-defpager: fix warnings about uninitialized variables, Samuel Thibault, 2014/03/19
- [hurd] 41/53: mach-defpager: fix warnings about unused variables, Samuel Thibault, 2014/03/19
- [hurd] 32/53: pfinet: improve the mig mutator functions, Samuel Thibault, 2014/03/19
- [hurd] 47/53: mach-defpager: silently ignore requests to page to active partition, Samuel Thibault, 2014/03/19
- [hurd] 46/53: mach-defpager: fix type of size arguments, Samuel Thibault, 2014/03/19
- [hurd] 35/53: pfinet: fix receiver lookups in iioctl-ops.c, Samuel Thibault, 2014/03/19
- [hurd] 49/53: Merge branch 'master' of git.savannah.gnu.org:/srv/git/hurd/hurd, Samuel Thibault, 2014/03/19