mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-21 07:39:08 +01:00
97eaadc3bfutil: Remove `fsbridge::get_filesystem_error_message()` (Hennadii Stepanov) Pull request description: The `fsbridge::get_filesystem_error_message()` function exhibits several drawbacks: 1. It was introduced in https://github.com/bitcoin/bitcoin/pull/14192 to account for platform-specific variations in `boost::filesystem::filesystem_error::what()`. Since [migrating](https://github.com/bitcoin/bitcoin/pull/20744) to `std::filesystem`, those discrepancies no longer exist. 2. It fails to display UTF-8 paths correctly on Windows: ``` > build\bin\Release\bitcoind.exe -datadir="C:\Users\hebasto\dd_₿_🏃" -regtest ... 2025-04-30T00:17:48Z DeleteAuthCookie: Unable to remove random auth cookie file: remove: Access is denied.: "C:\Users\hebasto\dd_?_??\regtest\.cookie" ... ``` 3. It relies on `std::wstring_convert`, which was deprecated in C++17 and removed in C++26 (also see https://github.com/bitcoin/bitcoin/issues/32361). This PR removes the obsolete `fsbridge::get_filesystem_error_message()` function, thereby resolving all of the above issues. ACKs for top commit: maflcko: lgtm re-ACK97eaadc3bfdavidgumberg: untested crACK97eaadc3bfachow101: ACK97eaadc3bflaanwj: Code review ACK97eaadc3bfTree-SHA512: 3c7378a9b143ac2a71add967318a13c346ae3bccbec6e9879d7873083f3fa469b3eef529b2c9c142b2489ba9563e4e12f685745c09a8a219d58b384f7ecf1be1