diff options
author | 2014-11-26 18:34:51 +0000 | |
---|---|---|
committer | 2014-11-26 18:34:51 +0000 | |
commit | b9a887b60dfe0bcd4be9bbd84cc3b6ef94586b9f (patch) | |
tree | 69fcd75ffe77994b2e1cb6398698e26414665990 /usr.bin/grep/grep.c | |
parent | Make caretx a perl dependency, not just miniperl (diff) | |
download | wireguard-openbsd-b9a887b60dfe0bcd4be9bbd84cc3b6ef94586b9f.tar.xz wireguard-openbsd-b9a887b60dfe0bcd4be9bbd84cc3b6ef94586b9f.zip |
Prefer setvbuf() to setlinebuf() for portability; ok deraadt@
Diffstat (limited to 'usr.bin/grep/grep.c')
-rw-r--r-- | usr.bin/grep/grep.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/grep/grep.c b/usr.bin/grep/grep.c index 592573b50ba..89830da8d44 100644 --- a/usr.bin/grep/grep.c +++ b/usr.bin/grep/grep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: grep.c,v 1.46 2014/11/26 17:26:40 millert Exp $ */ +/* $OpenBSD: grep.c,v 1.47 2014/11/26 18:34:51 millert Exp $ */ /*- * Copyright (c) 1999 James Howard and Dag-Erling Coïdan Smørgrav @@ -484,7 +484,7 @@ main(int argc, char *argv[]) } if (lbflag) - setlinebuf(stdout); + setvbuf(stdout, NULL, _IOLBF, 0); if ((argc == 0 || argc == 1) && !Rflag && !Hflag) hflag = 1; |