shithub: riscv

ref: c5c79d61e67f2c74a8d57eb1aeea87a23eeadd87
dir: /sys/src/ape/lib/ap/plan9/ttyname.c/

View raw version
#include <unistd.h>
#include <stdio.h>

char *
ttyname(int fd)
{
	static char buf[100];

	sprintf(buf, "/fd/%d", fd);
	return buf;
}