From 4a860d6be802a3fae1a98c78babafc94aa81334a Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Tue, 12 Jan 2010 23:54:15 +0000 Subject: [PATCH] Improve the default zzcat sequence to improve performance. --- doc/zzcat.1.in | 2 +- src/zzcat.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/zzcat.1.in b/doc/zzcat.1.in index 325729c..31196e4 100644 --- a/doc/zzcat.1.in +++ b/doc/zzcat.1.in @@ -51,7 +51,7 @@ Read a file or a stream using the instruction sequence specified in If no sequence is specified, the following default sequence is used: -\fB repeat(\-1, fgetc(), feof(1)) +\fB repeat(\-1, fread(1,32768), feof(1)) .TP \fB\-l\fR, \fB\-\-list\fR Display the list of supported keywords and functions and exit. diff --git a/src/zzcat.c b/src/zzcat.c index 9d407d7..7345c8b 100644 --- a/src/zzcat.c +++ b/src/zzcat.c @@ -73,7 +73,7 @@ static int number_nonblank = 0; int main(int argc, char *argv[]) { - char const *sequence = "repeat(-1, fgetc(), feof(1))"; + char const *sequence = "repeat(-1, fread(1,32768), feof(1))"; int i; for (;;)