Article # 256, added by Geoworks, historical record
| first |
previous |
index |
next |
last |
FileEnum returns an invalid number of files.
Q. FileEnum() is not returning the number of files that it finds. I am currently working around it by looking for invalid values in the file information structures as I go through the file array created by FileEnum(). When I see an invalid value (I'm already off the end of the array), I stop processing. A. This is a bug in the C stub for FileEnum(). Here is a better solution to the problem: count = MemGetInfo( memHan, MGIT_SIZE ) / sizeof( FEDosInfo ); where FEDosInfo could be the value you used for the FE_params.FEP_returnSize field before calling FileEnum, and memHan is the memory handle returned by FileEnum. The bug was fixed a long time ago, so this probably won't affect you.