Subversion Repositories planix.SVN

Rev

Rev 2 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
#include <unistd.h>
2
#include <stdio.h>
3
#include <string.h>
4
 
5
char *
6
ctermid(char *s)
7
{
8
	static char buf[L_ctermid];
9
 
10
	if(s == 0)
11
		s = buf;
12
	strncpy(s, "/dev/cons", sizeof buf);
13
	return(s);
14
}
15
 
16
char *
17
ctermid_r(char *s)
18
{
19
	return s ? ctermid(s) : NULL;
20
}