Teach crashinfo(8) to look at the currently running kernel (based on the
kern.bootfile sysctl). Prior to this commit, crashinfo(8) only looks at /boot/*/kernel; this includes the usual places where kernels reside, so for most systems this will have no effect. Approved by: jhb MFC after: 3 days
This commit is contained in:
parent
5d067f6cbf
commit
9decd44681
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=216077
@ -53,7 +53,7 @@ find_kernel()
|
||||
}' $INFO)
|
||||
|
||||
# Look for a matching kernel version.
|
||||
for k in /boot/kernel/kernel $(ls -t /boot/*/kernel); do
|
||||
for k in `sysctl -n kern.bootfile` $(ls -t /boot/*/kernel); do
|
||||
kvers=$(echo 'printf " Version String: %s", version' | \
|
||||
gdb -x /dev/stdin -batch $k 2>/dev/null)
|
||||
if [ "$ivers" = "$kvers" ]; then
|
||||
|
Loading…
Reference in New Issue
Block a user