WASM readdir will fail to return some database files correctly

Version: 1.38.2.0

Frequency: Consistently

Severity: Medium (File system reads should not be crashing the simulator)

Context: Navigraph MSFS Navigation Data Interface. WASM readdir problems as mentioned in this post.

Bug description: Basically, whenever certain files are put in a directory (namely our DFDv2 spec sqlite3 database files), the sim will either freeze, or return nothing as the filename for the database file. This is, however, fixed when you have a minimum of 3 files in the directory. Link to copying code

Repro steps: Try the 3 file tester, then the 2 file tester, and compare the results in the console (this should be just after loading in). As well as pay attention to the work/NavigationData folder, and how it improperly loops.

(The database should be included in the zip but can also be found here)

Attachments:
Resulting Copy File:

File it was copying from:

Link to both the sample aircraft in 1 zip:

Seems that our databases will freeze the sim on 2024 as well, is there something we need to change?

@katie,

Can you check if the issue is still there in the SU1 fighting build?
We made lots of fixes regarding file access from WASM in this build so hopefully it should have disappeared.
Please let me know if this is not the case.

Best regards,

Eric / Asobo

I haven’t tested it myself but I’m getting reports it’s no longer crashing, but the 3 file bug is still occuring, this time the 3rd file even needs to have content in it for it to work (just to confirm, this is in 2024 SU1 Beta)

Hello @katie,

I can confirm that there was still an issue with the readdir implementation - it has now been fixed and should be part of one of the SU1 Beta updates (probably not the next one though).

Best regards,

Eric / Asobo