--- a/kerneltest/e32test/mediaext/t_nfe.cpp Thu Aug 19 11:14:22 2010 +0300
+++ b/kerneltest/e32test/mediaext/t_nfe.cpp Tue Aug 31 16:34:26 2010 +0300
@@ -130,9 +130,9 @@
return r;
}
-void DisplayNfeDeviceInfo(TInt aNfeDrive, TNfeDeviceInfo& aDeviceInfo)
+void DisplayNfeDeviceInfo(TInt aNfeDrive, TNfeDeviceInfo& aDeviceInfo, TBool (&aNfeDrives)[KMaxLocalDrives])
{
- test.Printf(_L("Stats: \n"));
+// test.Printf(_L("Stats: \n"));
RLocalDrive d;
TBool change = EFalse;
@@ -153,6 +153,13 @@
{
TNfeDriveInfo& di = aDeviceInfo.iDrives[i];
+ TInt localDriveNum = di.iLocalDriveNum;
+ test_Value(localDriveNum, di.iLocalDriveNum < KMaxLocalDrives);
+
+ if (aNfeDrives[localDriveNum])
+ continue;
+ aNfeDrives[localDriveNum] = 1;
+
test.Printf(_L("*** drive index %d ***\n"), i);
test.Printf(_L("iLocalDriveNum %x\n"), di.iLocalDriveNum);
test.Printf(_L("iDriveLetter %c\n"), di.iDriveLetter >= 0 && di.iDriveLetter <= 25 ? di.iDriveLetter +'A' : '?');
@@ -389,10 +396,13 @@
}
+ TBool nfeDrives[KMaxLocalDrives];
+ memclr(nfeDrives, sizeof(nfeDrives));
+
for(TInt nfeDrive = FindNfeDrive(0); nfeDrive != KErrNotFound; nfeDrive = FindNfeDrive(++nfeDrive))
{
TNfeDeviceInfo deviceInfo;
- DisplayNfeDeviceInfo(nfeDrive, deviceInfo);
+ DisplayNfeDeviceInfo(nfeDrive, deviceInfo, nfeDrives);
}
fs.Close();