From a5d21a49ccdc6141790085d4bd26b667b8d5618d Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 21 Jan 2025 23:05:03 +0100 Subject: checkpoint --- bin/extra/gdbcore | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'bin/extra/gdbcore') diff --git a/bin/extra/gdbcore b/bin/extra/gdbcore index 6daafa8..f44a020 100755 --- a/bin/extra/gdbcore +++ b/bin/extra/gdbcore @@ -11,8 +11,9 @@ cache="$HOME/.cache/gdbcore_prog" -if [ "$#" -lt 1 ]; then +if [ "$1" = "-h" ]; then >&2 printf 'usage: gdbcore [-r] \n' + exit 1 fi if [ "$1" = "-r" ]; then @@ -64,6 +65,7 @@ else line="$(sed -n "${nr}p" "$tmp")" corefile="$coredir"/"${line%% *}" fi +>&2 printf 'corefile: %s\n' "$corefile" if [ ! -f "$corefile" ]; then rm -f "$tmp" -- cgit v1.2.3