]> git.ipfire.org Git - thirdparty/ccache.git/commit
Avoid duplicate stat calls (#550)
authorErik Johansson <erik@ejohansson.se>
Sun, 1 Mar 2020 20:17:49 +0000 (21:17 +0100)
committerGitHub <noreply@github.com>
Sun, 1 Mar 2020 20:17:49 +0000 (21:17 +0100)
commitdf961358240487afdc4a92eb4bc7db25e6f931de
treefcdfdcf9caac8b70e9d56565fc807851462d8343
parente0f5063b159de97ca9cc3dae8dbab67628ccb33d
Avoid duplicate stat calls (#550)

hash_source_code_string will, in read_file, stat the file to get the file
size. But when called from verify_result, the file size is already known so by
using this size the number of stat calls in a normal run can be cut in half.
src/hashutil.cpp
src/hashutil.hpp
src/manifest.cpp