aboutsummaryrefslogtreecommitdiff
path: root/src/compiler.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2019-03-11 10:26:08 -0400
committerAndrew Kelley <andrew@ziglang.org>2019-03-11 10:26:08 -0400
commit3a6f19de48366a616eaffd9dd6c4d4712e0b6c27 (patch)
tree60e0f7451f1dc6ac03153e0b3471f171825f35e3 /src/compiler.cpp
parentfec4555476e38d2eeb1dfb02572404b243acd0b2 (diff)
downloadzig-3a6f19de48366a616eaffd9dd6c4d4712e0b6c27.tar.gz
zig-3a6f19de48366a616eaffd9dd6c4d4712e0b6c27.zip
stage1 caching system: detect problematic mtimes
closes #2045
Diffstat (limited to 'src/compiler.cpp')
-rw-r--r--src/compiler.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/compiler.cpp b/src/compiler.cpp
index fa153aa2d8..7ec1485fad 100644
--- a/src/compiler.cpp
+++ b/src/compiler.cpp
@@ -75,8 +75,10 @@ Error get_compiler_id(Buf **result) {
cache_file(ch, &self_exe_path);
buf_resize(&saved_compiler_id, 0);
- if ((err = cache_hit(ch, &saved_compiler_id)))
- return err;
+ if ((err = cache_hit(ch, &saved_compiler_id))) {
+ if (err != ErrorInvalidFormat)
+ return err;
+ }
if (buf_len(&saved_compiler_id) != 0) {
cache_release(ch);
*result = &saved_compiler_id;