diff options
author | Stef Walter <stef@thewalter.net> | 2004-04-03 22:13:01 +0000 |
---|---|---|
committer | Stef Walter <stef@thewalter.net> | 2004-04-03 22:13:01 +0000 |
commit | bec23685136f78a24a78a6d8840d3865ffbccea9 (patch) | |
tree | 1453e0c5f87bb689a3df9c8e524d05d65bcca657 /src/list.c | |
parent | 3eca787a2b83ff8cf60d2be9e588d4a558b85a85 (diff) |
Unix porting.
Diffstat (limited to 'src/list.c')
-rw-r--r-- | src/list.c | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -99,7 +99,7 @@ int printPartitionInfo(int dd, uint64 tblSector) return 0; } - +#ifdef _WIN32 void scroungeList() { char driveName[MAX_PATH]; @@ -113,7 +113,7 @@ void scroungeList() { makeDriveName(driveName, i); - dd = open(driveName, _O_BINARY | _O_RDONLY | OPEN_LARGE_OPTS); + dd = open(driveName, O_BINARY | O_RDONLY | OPEN_LARGE_OPTS); if(dd != -1) { printf(kPrintDrive, i); @@ -122,14 +122,15 @@ void scroungeList() } } } +#endif void scroungeListDrive(char* drive) { - int dd = open(driveName, _O_BINARY | _O_RDONLY | OPEN_LARGE_OPTS; + int dd = open(drive, O_BINARY | O_RDONLY | OPEN_LARGE_OPTS); if(dd == -1) - err(1, "couldn't open drive: %s", driveName); + err(1, "couldn't open drive: %s", drive); - printf(kPrintDrivePath, driveName); + printf(kPrintDrivePath, drive); printPartitionInfo(dd, 0); close(dd); } |