zeroshade commented on code in PR #2918:
URL: https://github.com/apache/arrow-adbc/pull/2918#discussion_r2157285171
##########
c/driver_manager/adbc_driver_manager.cc:
##########
@@ -631,9 +993,95 @@ static const char kDefaultEntrypoint[] = "AdbcDriverInit";
} // namespace
// Other helpers (intentionally not in an anonymous namespace so they can be
tested)
+ADBC_EXPORT
+std::filesystem::path InternalAdbcUserConfigDir() {
+ std::filesystem::path config_dir;
+#if defined(_WIN32)
+ size_t required_size;
+ _wgetenv_s(&required_size, NULL, 0, L"AppData");
+ if (required_size == 0) {
+ return config_dir;
+ }
+
+ std::wstring app_data_value;
+ app_data_value.resize(required_size);
+ _wgetenv_s(&required_size, app_data_value.data(), required_size, L"AppData");
Review Comment:
updated to use `SHGetKnownFolderPath` (since the docs say your suggestion is
just an alias for `SHGetKnownFolderPath` since Vista)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]