[screenrecord.sh] Revert pidfile reading command, drop redundant return.

This commit is contained in:
Lorenzo Cogotti 2022-11-06 23:10:37 +01:00
parent 96cd1d5613
commit 6af80db57f
1 changed files with 1 additions and 2 deletions

View File

@ -27,9 +27,8 @@ pidfile="$XDG_RUNTIME_DIR/screenrecord.pid"
filename="$(xdg-user-dir VIDEOS)/ScreenCast_$(date +%F_%T).mp4"
isrunning() {
pid=$(2>/dev/null <"$pidfile")
pid=$(cat -- "$pidfile" 2>/dev/null)
test $? && kill -s 0 -- "$pid" 2>/dev/null
return $?
}
usage() {