With this PR there should be no longer chances of removing too many files during uninstall. The problem was that the code did not check if there was already system mount point mounted at requested folder thus leading to situation where there could be multiple mount points pointing to same folder. This lead to situation where the code thought that everything was unmounted when instead there was x times the mounts and accidentally removed everything (or what ever it was possible with root permissions).
Also, at least with Termux the host side environment variables were leaked inside the jail. Code will now try to ensure that clean start up is achieved. This helps ensure that stuff running inside the jail will not accidentally use host side binaries / settings, and cause instability and/or unintended functionality.
Changed --data flag to --android flag to generalize the feature flag. This way /data and /system mount points are not mounted by default to prevent accidental modifications to them. With the latest changes they can be mounted without problems, even /data with circular reference.
Updated the documentation to reflect current functionality.
Fixes #17 Ground work for #20
With this PR there should be no longer chances of removing too many files during uninstall. The problem was that the code did not check if there was already system mount point mounted at requested folder thus leading to situation where there could be multiple mount points pointing to same folder. This lead to situation where the code thought that everything was unmounted when instead there was x times the mounts and accidentally removed everything (or what ever it was possible with root permissions).
Also, at least with Termux the host side environment variables were leaked inside the jail. Code will now try to ensure that clean start up is achieved. This helps ensure that stuff running inside the jail will not accidentally use host side binaries / settings, and cause instability and/or unintended functionality.
Changed
--data
flag to--android
flag to generalize the feature flag. This way/data
and/system
mount points are not mounted by default to prevent accidental modifications to them. With the latest changes they can be mounted without problems, even/data
with circular reference.Updated the documentation to reflect current functionality.