Vasil Dimov 856c88776f ArgsManager: return path by value from GetBlocksDirPath()
`ArgsManager::m_cached_blocks_path` is protected by
`ArgsManager::cs_args` and returning a reference to it after releasing
the mutex is unsafe.

To resolve this, return a copy of the path. This has some performance
penalty which is presumably ok, given that paths are a few 100s bytes
at most and `GetBlocksDirPath()` is not called often.

This silences the following (clang 18):

```
common/args.cpp:288:31: error: returning variable 'm_cached_blocks_path' by reference requires holding mutex 'cs_args' [-Werror,-Wthread-safety-reference-return]
  288 |     if (!path.empty()) return path;
      |                               ^
```

Do the same with
`ArgsManager::GetDataDir()`,
`ArgsManager::GetDataDirBase()` and
`ArgsManager::GetDataDirNet()`.
2023-12-11 17:42:17 +01:00
..
2023-12-11 17:41:39 +01:00
2023-12-05 13:11:02 -05:00
2023-12-11 17:42:05 +01:00
2023-12-11 17:42:17 +01:00
2023-10-12 11:27:19 +02:00
2023-12-07 11:05:33 +01:00
2022-12-24 23:49:50 +00:00
2023-11-21 13:15:44 +00:00
2023-06-16 10:38:19 +01:00
2023-11-21 13:15:44 +00:00
2022-12-24 23:49:50 +00:00
2023-11-16 11:36:22 +10:00
2023-10-12 11:27:19 +02:00
2023-06-16 10:38:19 +01:00
2023-09-13 11:37:45 +01:00
2022-12-24 23:49:50 +00:00
2022-12-24 23:49:50 +00:00
2022-12-24 23:49:50 +00:00
2023-11-30 11:28:19 +01:00
2023-11-28 12:42:07 +01:00
2023-11-21 13:15:44 +00:00
2023-01-12 13:42:44 +00:00
2023-06-16 10:38:19 +01:00
2023-07-19 18:12:42 +02:00
2023-11-30 11:27:54 +01:00
2023-11-07 10:21:51 +09:00
2023-11-16 11:36:22 +10:00