Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/usr.bin/make Invalidate meta_fname when we finish a job, so ...



details:   https://anonhg.NetBSD.org/src/rev/aaed0915c3a7
branches:  trunk
changeset: 759743:aaed0915c3a7
user:      sjg <sjg%NetBSD.org@localhost>
date:      Wed Dec 15 23:03:35 2010 +0000

description:
Invalidate meta_fname when we finish a job, so that in compat
mode, we do not report a previous .meta file as being involved
in an error.

diffstat:

 usr.bin/make/meta.c |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diffs (20 lines):

diff -r e9fb64d3f760 -r aaed0915c3a7 usr.bin/make/meta.c
--- a/usr.bin/make/meta.c       Wed Dec 15 22:49:42 2010 +0000
+++ b/usr.bin/make/meta.c       Wed Dec 15 23:03:35 2010 +0000
@@ -574,7 +574,7 @@
     }
     getcwd(cwd, sizeof(cwd));
     Var_Set(".ERROR_CWD", cwd, VAR_GLOBAL, 0);
-    if (pbm) {
+    if (pbm && pbm->meta_fname[0]) {
        Var_Set(".ERROR_META_FILE", pbm->meta_fname, VAR_GLOBAL, 0);
     }
 }
@@ -644,6 +644,7 @@
        meta_cmd_finish(pbm);
        fclose(pbm->mfp);
        pbm->mfp = NULL;
+       pbm->meta_fname[0] = '\0';
     }
 }
 



Home | Main Index | Thread Index | Old Index