Refactor tty(1) code and manpage

This commit is contained in:
FRIGN
2015-02-07 22:00:28 +01:00
parent 352eedff58
commit 018d60c6bf
3 changed files with 19 additions and 7 deletions

2
tty.c
View File

@@ -1,6 +1,5 @@
/* See LICENSE file for copyright and license details. */
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include "util.h"
@@ -23,5 +22,6 @@ main(int argc, char *argv[])
tty = ttyname(STDIN_FILENO);
puts(tty ? tty : "not a tty");
return tty ? 0 : 1;
}