diff options
author | Pierre Fenoll <[email protected]> | 2017-12-14 16:16:40 +0100 |
---|---|---|
committer | Pierre Fenoll <[email protected]> | 2018-03-14 11:41:52 +0100 |
commit | 136105e82cff0a97a0ca653cbfee36a408260a4c (patch) | |
tree | cbe2ea3aff06ca7d4f8fd06377f9d9138fd0f243 /kerl | |
parent | 979d186088dc3051b22b5f94fffd4d4e76f57c09 (diff) | |
download | kerl-136105e82cff0a97a0ca653cbfee36a408260a4c.tar.gz kerl-136105e82cff0a97a0ca653cbfee36a408260a4c.tar.bz2 kerl-136105e82cff0a97a0ca653cbfee36a408260a4c.zip |
In kerl line 1113:
PARENT_CMD=$(ps -p $PARENT_PID -o ucomm | tail -n 1)
^-- SC2086: Double quote to prevent globbing and word splitting.
Diffstat (limited to 'kerl')
-rwxr-xr-x | kerl | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1114,8 +1114,9 @@ ACTIVATE_CSH fi PID=$$ - PARENT_PID=$(ps -p $PID -o ppid | grep -E "[0-9]+" -o) - PARENT_CMD=$(ps -p "$PARENT_PID" -o ucomm | tail -n 1) + PARENT_PID=$(ps -p $PID -o ppid=) || exit 1 + # shellcheck disable=SC2086 + PARENT_CMD=$(ps -p $PARENT_PID -o ucomm | tail -n 1) case "$PARENT_CMD" in fish) SHELL_SUFFIX=".fish" |