mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-27 11:17:38 +00:00
15 lines
352 B
Bash
15 lines
352 B
Bash
#!/system/bin/sh
|
|
|
|
HIDELIST=/magisk/.core/magiskhide/hidelist
|
|
PROCESS=$1
|
|
TOOLPATH=/dev/busybox
|
|
|
|
if [ ! -z "$PROCESS" ]; then
|
|
cp -af $HIDELIST $HIDELIST.tmp
|
|
cat $HIDELIST.tmp | grep -v "^$PROCESS$" > $HIDELIST
|
|
rm -f $HIDELIST.tmp
|
|
set --
|
|
set `$TOOLPATH/ps -o pid,args | grep "$PROCESS" | grep -v grep` >/dev/null
|
|
[ ! -z "$1" ] && kill "$1"
|
|
fi
|