diff options
Diffstat (limited to 'src/auto_detect_format.c')
| -rw-r--r-- | src/auto_detect_format.c | 5 | 
1 files changed, 5 insertions, 0 deletions
| diff --git a/src/auto_detect_format.c b/src/auto_detect_format.c index 6ec5f73..524e2e9 100644 --- a/src/auto_detect_format.c +++ b/src/auto_detect_format.c @@ -30,6 +30,11 @@   *   */  char *auto_detect_format(void) { +    /* If stdout is a tty, we output directly to a terminal. */ +    if (isatty(STDOUT_FILENO)) { +        return "term"; +    } +      pid_t myppid = getppid();      pid_t mypid = getpid(); | 
