Skip to content

Commit b5c3df5

Browse files
JunielKatarnasklar
andauthored
Use GetTempPath2W
As recommended in MS documentation. Co-authored-by: Alexander Sklar <[email protected]>
1 parent f6df4ab commit b5c3df5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vnext/Shared/OInstance.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ InstanceImpl::InstanceImpl(
396396
std::unique_ptr<facebook::jsi::PreparedScriptStore> preparedScriptStore;
397397

398398
wchar_t tempPath[MAX_PATH];
399-
if (GetTempPathW(MAX_PATH, tempPath)) {
399+
if (GetTempPath2W(std::size(tempPath), tempPath)) {
400400
preparedScriptStore =
401401
std::make_unique<facebook::react::BasePreparedScriptStoreImpl>(winrt::to_string(tempPath));
402402
}

0 commit comments

Comments
 (0)