External storage space is now not counted in total space

Added argument to getFileInfo() to disable adding the size of
mountpoints to a directory's size.

Fixes #5924