diff options
author | Russ Cox <rsc@swtch.com> | 2008-07-10 11:05:34 -0400 |
---|---|---|
committer | Russ Cox <rsc@swtch.com> | 2008-07-10 11:05:34 -0400 |
commit | fd652ac3195e155c8c0a4cb8ec104b029f40628e (patch) | |
tree | 20a3acca807272ab3dd6b993eef2a500b5813797 /bin | |
parent | c98946022a1d13840ac648fee0a0eaf58e3e34aa (diff) | |
download | plan9port-fd652ac3195e155c8c0a4cb8ec104b029f40628e.tar.gz plan9port-fd652ac3195e155c8c0a4cb8ec104b029f40628e.tar.bz2 plan9port-fd652ac3195e155c8c0a4cb8ec104b029f40628e.zip |
stack: look in core by default
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/stack | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -1,8 +1,11 @@ #!/usr/local/plan9/bin/rc -pid=$1 +if(~ $#* 0) + pid=core +if not + pid=$1 shift -if(! ~ $pid [0-9] [0-9]*[0-9] */core *.core core.* */core.*){ +if(! ~ $pid [0-9] [0-9]*[0-9] */core *.core core.* */core.* core){ name=$pid pid=`{psu|awk '$NF=="'$name'" {print $2}'} if(~ $#pid 0){ |