Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F96281564
D44086.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
619 B
Referenced Files
None
Subscribers
None
D44086.diff
View Options
diff --git a/sys/kern/tty.c b/sys/kern/tty.c
--- a/sys/kern/tty.c
+++ b/sys/kern/tty.c
@@ -1315,7 +1315,8 @@
struct xtty *xtlist, *xt;
struct tty *tp;
struct proc *p;
- int cansee, error;
+ int error;
+ bool cansee;
sx_slock(&tty_list_sx);
lsize = tty_list_count * sizeof(struct xtty);
@@ -1328,8 +1329,8 @@
TAILQ_FOREACH(tp, &tty_list, t_list) {
tty_lock(tp);
- if (tp->t_session != NULL) {
- p = tp->t_session->s_leader;
+ if (tp->t_session != NULL &&
+ (p = atomic_load_ptr(&tp->t_session->s_leader)) != NULL) {
PROC_LOCK(p);
cansee = (p_cansee(td, p) == 0);
PROC_UNLOCK(p);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Sep 25, 8:24 AM (14 h, 3 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
12747122
Default Alt Text
D44086.diff (619 B)
Attached To
Mode
D44086: Fix kernel panic with disabled ttys
Attached
Detach File
Event Timeline
Log In to Comment