Warner Losh 3888260471 Fix a bunch of issues (and a few non-issues but appeasement is easier
than arguing) Coverity found:

o Use open + fstat rather than stat + open to avoid any races for a
  file that's static for the life of the system. This will prevent any
  problems should someone insert a new device while installing a
  kernel in the future.
o Use strlcpy instead of strcpy as a failsafe to knowing that the
  strings can't possibly be larger than the buffer due to data
  source limits (though in the future these limits might be more
  dynamic).
o If we can't find the hints file, return rather than dereference
  a NULL pointer.
o Check for lastmod before calling strcmp in case a PNP entry
  comes before a module entry. That's not allowed, but within the
  realm of crazy things programmers do.
o Free lastmod before exiting search_hints() to avoid a leak.

CID: 1383971, 1383970, 1383969, 1383965, 1383963, 1383960
2017-12-27 18:30:24 +00:00
..
2017-12-09 15:59:10 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-10-29 08:17:03 +00:00
2017-11-30 20:33:45 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-11-30 20:33:45 +00:00
2017-10-31 00:07:04 +00:00
2017-10-29 08:17:03 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-10-31 00:07:04 +00:00
2017-01-28 02:22:15 +00:00