You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While reviewing MainPreferenceFragment.void exportProfiles$lambda$14() → ContentResolver-openOutputStream, I noticed a potential main-thread blocking risk around android.content.ContentResolver#openOutputStream(android.net.Uri).
The latest source still performs the operation synchronously:
android.content.ContentResolver#openOutputStream(android.net.Uri) can block the calling thread while Android resolves a provider, opens a stream, performs database work, contacts account services, touches storage, or waits on remote I/O, depending on the API and URI/backend involved.
The Risk & Impact
If this method is reached from a UI-thread path, the operation can cause visible jank, StrictMode violations in debug builds, or an ANR when the provider/backend is slow, blocked, or unreachable. I am phrasing this as a source-level risk because I verified the current source pattern but did not run an on-device reproduction.
Please confirm whether this method can be reached from UI callbacks in the current app flow. If so, the blocking operation should be moved to the project’s existing background/IO pattern, with only UI updates posted back to the main thread.
Verification
I checked the latest upstream source at ae28fd91931fe4d2d5aab044de9ceaf9ed07ad56 and found the sensitive operation still present in mobile/src/main/java/com/github/shadowsocks/ProfilesFragment.kt. This report is based on source-level inspection, not runtime reproduction.
Activity