Page MenuHomeFreeBSD

savecore: accept device names without the /dev/ prefix
ClosedPublic

Authored by asomers on Jun 29 2020, 12:52 AM.

Details

Summary

savecore: accept device names without the /dev/ prefix

dumpon has accepted device names without the prefix ever since r291207.
Since dumpon and savecore are always paired, they ought to accept the same
arguments. Prior to this change, specifying 'dumpdev="da3"' in
/etc/rc.conf, for example, would result in dumpon working just fine but
savecore complaining that "Dump device does not exist".

PR: 247618
Sponsored by: Axcient

Diff Detail

Repository
rS FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

asomers created this revision.Jun 29 2020, 12:52 AM
asomers requested review of this revision.Jun 29 2020, 12:52 AM
cem accepted this revision.Jun 29 2020, 4:26 AM

Just style/typo nits. Functionally, it looks good.

sbin/savecore/savecore.c
1004 ↗(On Diff #73850)

Should this be else if or on a separate line?

1175–1177 ↗(On Diff #73850)

Seems weird to add a single-line {} here

This revision is now accepted and ready to land.Jun 29 2020, 4:26 AM
bcr accepted this revision as: manpages.Jun 29 2020, 6:08 AM
bcr added a subscriber: bcr.

Also good by manpages. Thanks for this change!

This revision was automatically updated to reflect the committed changes.
asomers marked 2 inline comments as done.