From 53554e41e8ab9ba4d70787881d0a57b94eda1c63 Mon Sep 17 00:00:00 2001 From: Paul Smith Date: Sat, 9 Apr 2016 09:25:50 -0400 Subject: [PATCH] * job.c (child_error): Add filename length to output length. Reported by Dale Stimson --- job.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/job.c b/job.c index 62e2e56a..66dde71c 100644 --- a/job.c +++ b/job.c @@ -481,7 +481,7 @@ child_error (struct child *child, const struct file *f = child->file; const gmk_floc *flocp = &f->cmds->fileinfo; const char *nm; - size_t l = strlen (f->name); + size_t l; if (ignored && silent_flag) return; @@ -504,9 +504,9 @@ child_error (struct child *child, nm = a; } - OUTPUT_SET (&child->output); + l = strlen (pre) + strlen (nm) + strlen (f->name) + strlen (post); - l += strlen (pre) + strlen (post); + OUTPUT_SET (&child->output); if (exit_sig == 0) error (NILF, l + INTSTR_LENGTH,