Changeset 7704 for trunk/src/kernel32/disk.cpp
- Timestamp:
- Dec 30, 2001, 12:04:19 PM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/disk.cpp
r7645 r7704 1 /* $Id: disk.cpp,v 1.2 6 2001-12-17 16:23:19 sandervl Exp $ */1 /* $Id: disk.cpp,v 1.27 2001-12-30 11:04:19 sandervl Exp $ */ 2 2 3 3 /* … … 273 273 { 274 274 CHAR tmpstring[256]; 275 CHAR szOrgFileSystemName[256] = ""; 275 276 ULONG drive; 276 277 BOOL rc; … … 304 305 } 305 306 } 306 if(lpFileSystemNameBuffer || lpMaximumComponentLength || lpFileSystemFlags) { 307 if(lpFileSystemNameBuffer || lpMaximumComponentLength || lpFileSystemFlags) 308 { 307 309 if(!lpFileSystemNameBuffer) { 308 310 lpFileSystemNameBuffer = tmpstring; … … 310 312 } 311 313 rc = OSLibDosQueryVolumeFS(drive, lpFileSystemNameBuffer, nFileSystemNameSize); 314 //save original file system name 315 if(rc == ERROR_SUCCESS) strcpy(szOrgFileSystemName, lpFileSystemNameBuffer); 316 312 317 if(lpFileSystemNameBuffer) 313 318 { … … 319 324 else 320 325 if(!strcmp(lpFileSystemNameBuffer, "CDFS") || 321 !strcmp(lpFileSystemNameBuffer, "UDF")) 326 !strcmp(lpFileSystemNameBuffer, "UDF") || 327 !strcmp(lpFileSystemNameBuffer, "FAT32") || 328 !strcmp(lpFileSystemNameBuffer, "NTFS")) //in case somebody ever writes one 322 329 { 323 330 //do nothing … … 331 338 } 332 339 if(lpMaximumComponentLength) { 333 if(!strcmp( lpFileSystemNameBuffer, "FAT16")) {334 *lpMaximumComponentLength = 12;335 } 336 else 340 if(!strcmp(szOrgFileSystemName, "FAT16") || !strcmp(szOrgFileSystemName, "FAT")) { 341 *lpMaximumComponentLength = 12; //8.3 342 } 343 else *lpMaximumComponentLength = 255; //TODO: Always correct? (CDFS?) 337 344 } 338 345 if(lpFileSystemFlags) 339 346 { 340 347 if(strcmp(lpFileSystemNameBuffer, "FAT16")) { 341 *lpFileSystemFlags = FS_CASE_IS_PRESERVED;348 *lpFileSystemFlags = FS_CASE_IS_PRESERVED; 342 349 } 343 350 else 344 351 if(!strcmp(lpFileSystemNameBuffer, "CDFS")) { 345 *lpFileSystemFlags = FS_CASE_SENSITIVE; //NT4 returns this352 *lpFileSystemFlags = FS_CASE_SENSITIVE; //NT4 returns this 346 353 } 347 354 else 348 355 if(!strcmp(lpFileSystemNameBuffer, "UDF")) {//TODO: correct? 349 *lpFileSystemFlags = FS_CASE_SENSITIVE | FS_UNICODE_STORED_ON_DISK;350 } 351 else 356 *lpFileSystemFlags = FS_CASE_SENSITIVE | FS_UNICODE_STORED_ON_DISK; 357 } 358 else *lpFileSystemFlags = 0; 352 359 353 360 dprintf2(("File system flags: %x", lpFileSystemFlags));
Note:
See TracChangeset
for help on using the changeset viewer.