summaryrefslogtreecommitdiffstats
path: root/term-utils
diff options
context:
space:
mode:
authorKarel Zak2017-04-13 15:04:54 +0200
committerKarel Zak2017-04-13 15:04:54 +0200
commit59868828e408c522ffc62771a71fa3ccaa7b21cd (patch)
treeffdbaa0db04c3bb0b75f544c3bf0922f1351a70b /term-utils
parentlibsmartcols: fix typo (diff)
parentscript: fix start message showing in output file when -q is on (diff)
downloadkernel-qcow2-util-linux-59868828e408c522ffc62771a71fa3ccaa7b21cd.tar.gz
kernel-qcow2-util-linux-59868828e408c522ffc62771a71fa3ccaa7b21cd.tar.xz
kernel-qcow2-util-linux-59868828e408c522ffc62771a71fa3ccaa7b21cd.zip
Merge branch 'script_quiet' of https://github.com/renyuneyun/util-linux
* 'script_quiet' of https://github.com/renyuneyun/util-linux: script: fix start message showing in output file when -q is on
Diffstat (limited to 'term-utils')
-rw-r--r--term-utils/script.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/term-utils/script.c b/term-utils/script.c
index d1ef07203..a58590188 100644
--- a/term-utils/script.c
+++ b/term-utils/script.c
@@ -435,7 +435,8 @@ static void do_io(struct script_control *ctl)
strftime(buf, sizeof buf, "%c\n", localtime(&tvec));
- fprintf(ctl->typescriptfp, _("Script started on %s"), buf);
+ if (!ctl->quiet && ctl->typescriptfp)
+ fprintf(ctl->typescriptfp, _("Script started on %s"), buf);
gettime_monotonic(&ctl->oldtime);
while (!ctl->die) {