diff options
| author | 2023-06-26 20:55:28 -0400 | |
|---|---|---|
| committer | 2023-06-26 22:24:18 -0400 | |
| commit | 9074a70b0180057d0cebcd667ad7fc813f1aca8c (patch) | |
| tree | cdec0c48f4a2f93f23ff1b9d961a5a18a3a3f6ae /src/common/fs | |
| parent | Merge pull request #10908 from kiri11/clarify-ring-ui (diff) | |
| download | yuzu-9074a70b0180057d0cebcd667ad7fc813f1aca8c.tar.gz yuzu-9074a70b0180057d0cebcd667ad7fc813f1aca8c.tar.xz yuzu-9074a70b0180057d0cebcd667ad7fc813f1aca8c.zip | |
android: Fix size check for content uris
Fix for checking file size for android content uris
Diffstat (limited to 'src/common/fs')
| -rw-r--r-- | src/common/fs/fs.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/common/fs/fs.cpp b/src/common/fs/fs.cpp index 1baf6d746..36e67c145 100644 --- a/src/common/fs/fs.cpp +++ b/src/common/fs/fs.cpp | |||
| @@ -605,6 +605,12 @@ fs::file_type GetEntryType(const fs::path& path) { | |||
| 605 | } | 605 | } |
| 606 | 606 | ||
| 607 | u64 GetSize(const fs::path& path) { | 607 | u64 GetSize(const fs::path& path) { |
| 608 | #ifdef ANDROID | ||
| 609 | if (Android::IsContentUri(path)) { | ||
| 610 | return Android::GetSize(path); | ||
| 611 | } | ||
| 612 | #endif | ||
| 613 | |||
| 608 | std::error_code ec; | 614 | std::error_code ec; |
| 609 | 615 | ||
| 610 | const auto file_size = fs::file_size(path, ec); | 616 | const auto file_size = fs::file_size(path, ec); |