From 1bb275a22bf9cbfe3d18db6eb86a1bc8524810f8 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Thu, 5 Jan 2012 15:49:26 +0100 Subject: [PATCH] Use hash_compiler for explicit --specs= options as well --- ccache.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/ccache.c b/ccache.c index 8b9b5f390..cd9d08c09 100644 --- a/ccache.c +++ b/ccache.c @@ -927,14 +927,12 @@ calculate_object_hash(struct args *args, struct mdfour *hash, int direct_mode) } } - if (str_startswith(args->argv[i], "--specs=") && - stat(args->argv[i] + 8, &st) == 0) { - /* If given a explicit specs file, then hash that file, + if (str_startswith(args->argv[i], "--specs=") + && stat(args->argv[i] + 8, &st) == 0) { + /* If given an explicit specs file, then hash that file, but don't include the path to it in the hash. */ hash_delimiter(hash, "specs"); - if (!hash_file(hash, args->argv[i] + 8)) { - failed(); - } + hash_compiler(hash, &st, args->argv[i] + 8, false); continue; } -- 2.47.2