darwin: rewrite mount_get_mountpoint
Rewrite most of mount_get_mountpoint for Darwin using the DiskArbitration API instead of the more low level getfsstat. This fixes a memory over-read leading to a crash when the system has more than 128 mounts. Additionally it changes the logic a bit, now it is first checked if the path exists and is a folder, if that is not the case, try to interpret it as BSD mount name, this makes BSD names like 'disk2' work (provided there is no folder/image with that name) as expected. Reported by Collin Allen. Fix #21
Loading
Please register or sign in to comment