LSPosed/daemon
JingMatrix 3540f14481
Gracefully handle ENOTSUP in ConfigFileManager.chattr0 (#523)
The `chattr0` method, which attempts to clear special file attributes (like 'i' for immutable) using `ioctl`, can fail with an `ErrnoException` and the error code `ENOTSUP` (Operation not supported) on certain filesystems or Android environments (e.g., noted on a Android 11 device).

When `ioctl` fails with `ENOTSUP`, it means the underlying filesystem does not support the operation of setting/clearing these attributes. In this case, we can safely assume the file/directory is not immutable via this mechanism and treat the operation as a successful non-action.

This commit updates `chattr0` to catch `ErrnoException` specifically and return `true` if the error is `OsConstants.ENOTSUP`, preventing unexpected failures in config file management.
2026-01-31 15:51:03 +01:00
..
src/main Gracefully handle ENOTSUP in ConfigFileManager.chattr0 (#523) 2026-01-31 15:51:03 +01:00
.gitignore Refactor `core` to use LSPlant as the ART hook framework (#1756) 2022-03-15 07:51:30 +08:00
build.gradle.kts Centralize dependencies and migrate to submodules (#512) 2026-01-22 15:13:06 +01:00
proguard-rules.pro Fix incorrect mount point on Android 10 (#1870) 2022-04-21 01:40:48 +00:00