Skip to content

Commit 7341fb5

Browse files
kernel: ctty -> tty
This is because a lot of programs expect it to work that way. `vtty` is fine because currently X is the only dependent on that and will be. Signed-off-by: Anhad Singh <[email protected]>
1 parent 5e9ea37 commit 7341fb5

File tree

3 files changed

+21
-23
lines changed

3 files changed

+21
-23
lines changed

src/aero_kernel/src/drivers/tty/ctty.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
// You should have received a copy of the GNU General Public License
1616
// along with Aero. If not, see <https://www.gnu.org/licenses/>.
1717

18-
//! `/dev/ctty`: Controlling terminal of the current process.
18+
//! `/dev/tty`: Controlling terminal of the current process.
1919
2020
use aero_syscall::TIOCNOTTY;
2121
use alloc::sync::{Arc, Weak};
@@ -102,7 +102,7 @@ impl Device for Ctty {
102102

103103
#[inline]
104104
fn device_name(&self) -> String {
105-
String::from("ctty")
105+
String::from("tty")
106106
}
107107

108108
#[inline]

src/aero_kernel/src/drivers/tty/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
// You should have received a copy of the GNU General Public License
1616
// along with Aero. If not, see <https://www.gnu.org/licenses/>.
1717

18-
// `/dev/ctty`: controlling terminal of the process
18+
// `/dev/tty`: controlling terminal of the process
1919
// `/dev/vtty[0-9]`: virtual terminals
2020

2121
mod ctty;
@@ -364,7 +364,7 @@ impl devfs::Device for Tty {
364364
}
365365

366366
fn device_name(&self) -> String {
367-
String::from("tty")
367+
String::from("vtty")
368368
}
369369

370370
fn inode(&self) -> Arc<dyn inode::INodeInterface> {

userland/apps/init/src/main.rs

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,26 @@
1-
/*
2-
* Copyright (C) 2021-2022 The Aero Project Developers.
3-
*
4-
* This file is part of The Aero Project.
5-
*
6-
* Aero is free software: you can redistribute it and/or modify
7-
* it under the terms of the GNU General Public License as published by
8-
* the Free Software Foundation, either version 3 of the License, or
9-
* (at your option) any later version.
10-
*
11-
* Aero is distributed in the hope that it will be useful,
12-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
* GNU General Public License for more details.
15-
*
16-
* You should have received a copy of the GNU General Public License
17-
* along with Aero. If not, see <https://www.gnu.org/licenses/>.
18-
*/
1+
// Copyright (C) 2021-2022 The Aero Project Developers.
2+
//
3+
// This file is part of The Aero Project.
4+
//
5+
// Aero is free software: you can redistribute it and/or modify
6+
// it under the terms of the GNU General Public License as published by
7+
// the Free Software Foundation, either version 3 of the License, or
8+
// (at your option) any later version.
9+
//
10+
// Aero is distributed in the hope that it will be useful,
11+
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
// GNU General Public License for more details.
14+
//
15+
// You should have received a copy of the GNU General Public License
16+
// along with Aero. If not, see <https://www.gnu.org/licenses/>.
1917

2018
use std::error::Error;
2119
use std::fs::{File, OpenOptions};
2220
use std::os::fd::AsRawFd;
2321
use std::process::Command;
2422

25-
const TTY_PATH: &str = "/dev/tty";
23+
const TTY_PATH: &str = "/dev/vtty";
2624
const DEV_NULL: &str = "/dev/null";
2725

2826
struct FileSet<const N: usize>([File; N]);

0 commit comments

Comments
 (0)