mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-26 12:17:52 +00:00
Kernel+LibC: Switch isatty() to use a fcntl()
We would want it to work with only stdio pledged.
This commit is contained in:
parent
f9cffda0e0
commit
7541122206
Notes:
sideshowbarker
2024-07-19 06:22:57 +09:00
Author: https://github.com/bugaevc
Commit: 7541122206
Pull-request: https://github.com/SerenityOS/serenity/pull/2299
Reviewed-by: https://github.com/awesomekling
4 changed files with 5 additions and 2 deletions
|
@ -413,8 +413,7 @@ int rmdir(const char* pathname)
|
|||
|
||||
int isatty(int fd)
|
||||
{
|
||||
struct termios dummy;
|
||||
return tcgetattr(fd, &dummy) == 0;
|
||||
return fcntl(fd, F_ISTTY);
|
||||
}
|
||||
|
||||
int dup(int old_fd)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue