Skip to content

Commit 8d0a0ee

Browse files
committed
Fix copy
1 parent aa64d44 commit 8d0a0ee

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

scripts/util_functions.sh

+3-5
Original file line numberDiff line numberDiff line change
@@ -586,11 +586,9 @@ copy_preinit_files() {
586586
done > $PREINITDIR/sepolicy.rule
587587

588588
# Copy all enabled rc
589-
find "$PREINITDIR" -mindepth 1 -type d 2>/dev/null | while read -r dir; do
590-
rm -rf "${dir:?}"
591-
done
592-
for d in /data/adb/modules*/*; do
593-
local MODDIR=${d%/*}
589+
find "$PREINITDIR/" -mindepth 1 -maxdepth 1 -type d -exec rm -rf {} \;
590+
find /data/adb/modules* -mindepth 1 -maxdepth 1 -type d 2>/dev/null | while read -r MODDIR; do
591+
ui_print "MODDIR=$MODDIR"
594592
local MODID=$(basename "$MODDIR")
595593
[ -f "$MODDIR"/disable ] && continue
596594
[ -f "$MODDIR"/remove ] && continue

0 commit comments

Comments
 (0)