02-19-2013 03:08 PM
Figured it out.
The 'ls -lRi' on /accounts/1000/removable shows that all the files that don't show up using QDIr/QDirIterator have inodes greater than 32 bits. This seems to indicate that QDir and QDirIterator don't have large file support yet.
The solution to recusively list all files and directories on an HC SD card is to use the C code I posted above but to also put these lines in your .pro file:
DEFINES += _FILE_OFFSET_BITS=64
DEFINES += _LARGEFILE64_SOURCE=1
02-20-2013 03:42 AM
Ugh. Missed the bit in your post about using the C code. So no QDirIterator. Makes that a bit of a useless API until it's fixed. I wonder what the built in file manager uses... Something else, apparently.
04-11-2013 04:26 PM
I would like to confirm that bug with file API exists and can be fixed by defining:
or using readdir64() API directly.
I believe this is BB10 OS bug because only readdir64() is able to list files/directories with inode with > 64 bit value, readdir() does not list such items.
04-12-2013 03:50 AM
I can't access that ticket. I submitted it previously as https://www.blackberry.com/jira/browse/BBTEN-878. Still marked "Triage". How hard is it to add in a couple compile flags for the Qt/Cascades libraries?
04-12-2013 03:56 AM - edited 04-12-2013 03:58 AM
Although I guess one aspect of a more complete fix might be to get the QNX FAT32 driver to not generate inodes larger than 32 bits...
EDIT: Nah. That might be limiting in the future.
04-15-2013 04:52 AM
I can't access your ticket either and getting:
You cannot view this issue because you are not the issue reporter or assignee, a member of the project group, or a member of the issue group and this issue is closed or in triage.
I can add comment in my ticket regarding your submission too in order to have them linked to each other.
> That might be limiting in the future.
I think so too. It is better to fix 32-bit aware readdir() implementation so it would not skip entries with 64-bit inodes, moreover dirent structure does not have problem handling 64-bit inode value:
#elif !defined(_FILE_OFFSET_BITS) || _FILE_OFFSET_BITS == 32
ino_t d_ino; /* File serial number. */