Run savecore(8) only if there is a core dump to save. If there is
no core dump hide the message to that effect behind $rc_quiet.
This commit is contained in:
parent
ebef621a5c
commit
0203c01701
@ -57,8 +57,11 @@ savecore_prestart()
|
||||
|
||||
savecore_start()
|
||||
{
|
||||
[ -z "${rc_quiet}" ] && echo "Checking for core dump on ${dumpdev}..."
|
||||
savecore ${savecore_flags} ${DUMPDIR} ${dumpdev}
|
||||
if savecore -C >/dev/null; then
|
||||
savecore ${savecore_flags} ${DUMPDIR} ${dumpdev}
|
||||
else
|
||||
[ -z "${rc_quiet}" ] && echo "No core dumps found"
|
||||
fi
|
||||
}
|
||||
|
||||
load_rc_config $name
|
||||
|
Loading…
Reference in New Issue
Block a user