Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

isChildDocument(): Normalize paths before comparison #45

Merged
merged 1 commit into from
Dec 22, 2023

Commits on Dec 22, 2023

  1. isChildDocument(): Normalize paths before comparison

    Otherwise, duplicate and trailing slashes can result in an incorrect
    return value, which breaks apps that perform URI manipulation instead of
    using URIs returned by SAF.
    
    This commit partially reverts 78cf92a
    also. If the parent and child refer to the same path, isChildDocuments()
    will now return true. This is counter to what the SAF documentation
    says, but AOSP's FileSystemProvider behaves this way and apps now rely
    on that behavior.
    
    Fixes: #44
    
    Signed-off-by: Andrew Gunnerson <accounts+github@chiller3.com>
    chenxiaolong committed Dec 22, 2023
    Configuration menu
    Copy the full SHA
    ef1a7d9 View commit details
    Browse the repository at this point in the history