Shell (Linux): always detect tty id

This commit is contained in:
李通洲
2024-02-27 16:35:47 +08:00
parent 79b7b15b46
commit a3c3f3829d
@@ -148,12 +148,7 @@ static const char* getProcessNameAndPpid(pid_t pid, char* name, pid_t* ppid, int
return "sscanf(stat) failed";
if (tty)
{
if ((tty_ >> 8) == 0x88)
*tty = tty_ & 0xFF;
else
*tty = -1;
}
*tty = tty_ & 0xFF;
#elif defined(__APPLE__)