If stat returns an error other than the directory not existing it was unhandled. When IsDir is called in one of these situations it causes a panic. Closes #8181 Signed-off-by: Matt Farina <matt@mattfarina.com> (cherry picked from commit f182ebc11c)
f182ebc11c