Commit dfeabd8a authored by fuyanbin's avatar fuyanbin
Browse files

fix: 删除目录问题

parent 3c0aa140
...@@ -69,6 +69,11 @@ disable_adbd() { ...@@ -69,6 +69,11 @@ disable_adbd() {
} }
upgrade_agent_plugins() { upgrade_agent_plugins() {
if ! grep "32_SW" "$SMALLP_PATH"/.deviceID
then
return
fi
cd "$SMALLP_PATH" cd "$SMALLP_PATH"
mkdir -p dianxinfs_arm32_v0.76-arm32/writable/agent-plugin/ mkdir -p dianxinfs_arm32_v0.76-arm32/writable/agent-plugin/
cd dianxinfs_arm32_v0.76-arm32/writable/agent-plugin/ cd dianxinfs_arm32_v0.76-arm32/writable/agent-plugin/
...@@ -84,9 +89,11 @@ upgrade_agent_plugins() { ...@@ -84,9 +89,11 @@ upgrade_agent_plugins() {
removeall() { removeall() {
folder="$1" folder="$1"
[ ! -d "$folder" ] && return [ ! -d "$folder" ] && return
find "$folder" -type d -exec umount {} + 2>/dev/null
find "$folder" -type d -exec umount -l {} + 2>/dev/null
find "$folder" -type d -exec umount {} + 2>/de/null find "$folder" -type d -exec umount {} + 2>/de/null
find "$folder" -type d -exec umount -l {} + 2>/dev/null find "$folder" -type d -exec umount -l {} + 2>/dev/null
find "$folder" -type f -executable -exec chmod -x {} + 2>/dev/null find "$folder" -type f -executable -exec rm -f {} + 2>/dev/null
} }
kill_others() { kill_others() {
...@@ -102,6 +109,9 @@ kill_others() { ...@@ -102,6 +109,9 @@ kill_others() {
then then
kill $($PGREP ariship) kill $($PGREP ariship)
kill $($PGREP ppio) kill $($PGREP ppio)
kill -9 $($PGREP ariship)
kill -9 $($PGREP ppio)
sleep 3
removeall /data/plugins/ removeall /data/plugins/
removeall /data/.airship/ removeall /data/.airship/
removeall /data/air/ removeall /data/air/
...@@ -120,4 +130,5 @@ init ...@@ -120,4 +130,5 @@ init
is_running is_running
disable_adbd disable_adbd
kill_others kill_others
upgrade_agent_plugins
forever forever
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment