From bec23685136f78a24a78a6d8840d3865ffbccea9 Mon Sep 17 00:00:00 2001 From: Stef Walter Date: Sat, 3 Apr 2004 22:13:01 +0000 Subject: Unix porting. --- src/list.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/list.c') diff --git a/src/list.c b/src/list.c index 97ac912..fc30ac0 100644 --- a/src/list.c +++ b/src/list.c @@ -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); } -- cgit v1.2.3