diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c index 5414b1910451..6ca95bd56b86 100644 --- a/sbin/savecore/savecore.c +++ b/sbin/savecore/savecore.c @@ -172,6 +172,13 @@ getbounds(void) char buf[6]; int ret; + /* + * If we are just checking, then we haven't done a chdir to the dump + * directory and we should not try to read a bounds file. + */ + if (checkfor) + return (0); + ret = 0; if ((fp = fopen("bounds", "r")) == NULL) {