Skip to content

Commit caef71a

Browse files
author
Junio C Hamano
committed
Do not fork PAGER=cat
Unless the user has a nonstandard "cat" command that does not meow like a cat, this should not break anything and would save an extra pipe. Signed-off-by: Junio C Hamano <junkio@cox.net>
1 parent 402461a commit caef71a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pager.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ void setup_pager(void)
2020
return;
2121
if (!pager)
2222
pager = "less";
23-
else if (!*pager)
23+
else if (!*pager || !strcmp(pager, "cat"))
2424
return;
2525

2626
if (pipe(fd) < 0)

0 commit comments

Comments
 (0)