bitcoin/bitcoin — pull request #1281 by jgarzik (2012-05-13 07:13:14+00:00)
Title: Prefer direct access to cached pathDataDir, rather than calling a function

Even with the GetDataDir() cached system, a function call is overkill for the vast majority of uses in the code. The values are static once the program is initialized, so initialize pathDataDir once.

GetDataDir() is renamed to GetPrepDataDir() to better indicate that it has side effects.

Curious to see whether people think this is worth merging or not. I think it cleans up the code, and is ever so slightly more CPU efficient for most use cases.