mirror of https://github.com/bitcoin/bitcoin
Merge #16300: util: Explain why the path is cached
pull/16303/headfa69c3e6ca
util: Explain why the path is cached (MarcoFalke) Pull request description: The rationale for caching the datadir is given as ``` // This can be called during exceptions by LogPrintf(), so we cache the // value so we don't have to do memory allocations after that. ``` Since8c2d695c4a
, the debug log location is actually cached itself in `m_file_path`. So explain that the caching is now only used to guard against disk access on each call. (See also #16255) ACKs for top commit: promag: ACKfa69c3e6ca
. laanwj: ACKfa69c3e6ca
ryanofsky: utACKfa69c3e6ca
. Good cleanup. Previous comment was confusing, and definitely not helpful if outdated. Tree-SHA512: 02108c90026d6d7c02843aaf59a06b4e1fa63d5d4378bb7760f50767efc340dc94c259bf7afb32fa4d47952b48a4e91798d1e0ddc1b051d770405e078636793a
commit
935cd6b1ec
Loading…
Reference in new issue