shithub: riscv

ref: 37a5e86bf0aaffb1cdc841150ecc9c847b795e9b
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;
}