Skip to content

Commit

Permalink
build fix2
Browse files Browse the repository at this point in the history
  • Loading branch information
rzaharia committed Oct 26, 2024
1 parent 8c92fe8 commit 455f50d
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions GViewCore/src/View/DissasmViewer/DissasmCache.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ bool DissasmCache::SaveCacheFile(std::u16string_view location)

bool DissasmCache::LoadCacheFile(std::u16string_view location)
{
cacheFile.open(location, std::ios::in | std::ios::binary);
const std::filesystem::path filePath(location.begin(), location.end());
cacheFile.open(filePath, std::ios::in | std::ios::binary);
if (!cacheFile.is_open())
return false;
cacheFile.seekg(0, std::ios::end);
Expand Down Expand Up @@ -171,9 +172,6 @@ void Instance::SaveCacheData()
return;
}

constexpr char16 currentLoc = '.';
const auto cacheDataLocation = config.CacheSameLocationAsAnalyzedFile ? obj->GetPath() : std::u16string_view(&currentLoc, 1);

const std::filesystem::path path = DissasmCache::GetCacheFilePath(obj->GetPath(), config.CacheSameLocationAsAnalyzedFile);
cacheData.SaveCacheFile(path.u16string());
}
Expand Down

0 comments on commit 455f50d

Please sign in to comment.