From: Joel Rosdahl Date: Fri, 22 Jul 2022 20:35:35 +0000 (+0200) Subject: fix: Restore order of cpp and cppstderr sections in input hash X-Git-Tag: v4.6.2~14 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7242372e734597a006b70ebf3d1c7dca212b4920;p=thirdparty%2Fccache.git fix: Restore order of cpp and cppstderr sections in input hash This retains input hash compatibility with revisions before 64fc42ca2c5c9fe60ef4f1dc3882edb5f35579d6. (cherry picked from commit 11f3d650f94fce6766302642c74b92462c263bdd) --- diff --git a/src/ccache.cpp b/src/ccache.cpp index 561b5c3d8..ec33db832 100644 --- a/src/ccache.cpp +++ b/src/ccache.cpp @@ -1170,12 +1170,12 @@ get_result_key_from_cpp(Context& ctx, Args& args, Hash& hash) cpp_stderr_data = result->stderr_data; } - hash.hash_delimiter("cppstderr"); - hash.hash(cpp_stderr_data); - hash.hash_delimiter("cpp"); TRY(process_preprocessed_file(ctx, hash, preprocessed_path)); + hash.hash_delimiter("cppstderr"); + hash.hash(cpp_stderr_data); + ctx.i_tmpfile = preprocessed_path; if (!ctx.config.run_second_cpp()) {