Changeset 30281 in vbox for trunk/src/VBox/Runtime/r3
- Timestamp:
- Jun 17, 2010 10:25:10 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/r3/posix/fs-posix.cpp
r30254 r30281 35 35 #ifdef RT_OS_LINUX 36 36 # include <mntent.h> 37 #endif 38 #ifdef RT_OS_DARWIN 39 # include <sys/mount.h> 37 40 #endif 38 41 … … 228 231 if (!strcmp("zfs", Stat.st_fstype)) 229 232 *pu32Type = RTFS_FS_TYPE_ZFS; 233 #elif defined(RT_OS_DARWIN) 234 struct statfs statfsBuf; 235 if (!statfs(pszNativeFsPath, &statfsBuf)) 236 { 237 if (!strcmp("hfs", statfsBuf.f_fstypename)) 238 *pu32Type = RTFS_FS_TYPE_HFS; 239 else if ( !strcmp("fat", statfsBuf.f_fstypename) 240 || !strcmp("msdos", statfsBuf.f_fstypename)) 241 *pu32Type = RTFS_FS_TYPE_FAT; 242 else if (!strcmp("ntfs", statfsBuf.f_fstypename)) 243 *pu32Type = RTFS_FS_TYPE_NTFS; 244 else if (!strcmp("autofs", statfsBuf.f_fstypename)) 245 *pu32Type = RTFS_FS_TYPE_AUTOFS; 246 else if (!strcmp("devfs", statfsBuf.f_fstypename)) 247 *pu32Type = RTFS_FS_TYPE_DEVFS; 248 else if (!strcmp("nfs", statfsBuf.f_fstypename)) 249 *pu32Type = RTFS_FS_TYPE_NFS; 250 } 230 251 #endif 231 252 }
Note:
See TracChangeset
for help on using the changeset viewer.