savecore: fix space calculation with respect to `minfree` in check_space(..)
- Adjust `spacefree` and `totfree` calculations- Use strtoll(3) instead of atoi(3), so instead ofbecause atoi(3) limits the
multiplying too large quantities that can overflow,representable data to INT_MAX. Check the bsizevalues received from
(assumed to be a multiple of 1024) will instead be adjusted andstrtoll(3), trimming trailing whitespace off the end to maintain
multiplied to `f_bavail` or `f_bfree`, respectively.
- Use strtoll instead of atoi (atoi limits the representable data
to INT_MAX). Check the values received from strtoll, trimming
trailing whitespace off the end (to maintain POLA).
- Use the type-width appropriate types for `spacefree`, `totfree`,
etc (the values of `f_bavail`, `f_bfree`, etc are all *int64_t)POLA.
- Store available number of kB in `available` so it can be more
easily queried and compared to ensure that there are enough kB to
store the dump image on disk.
- Print out the reserved space on disk, per `minfree`, so end-users
can troubleshoot why check_space(..) is reporting that there isn't
enough free space.
MFC after: 7 weeks
Tested with: positive/negative cases; make tinderbox
Sponsored by: Dell EMC Isilon