Pull Request Overview
- Opened on September 16, 2026
- Status Open
- Commit count 1 with first commit September 16, 2026
Total Delta
Open Days
Test Delta
How long has this pull request spent in each phase of its lifecycle?
| Fraction of total time | Business days | Phase |
|---|---|---|
| N/A | 1014.0 days | Issue creation to work beginning |
|
|
0.1 days | Authoring 1 commit before pull request opened for review |
|
|
0.1 days | Awaiting first review |
|
|
2.5 days | Revising work with 0 commits in response to 1 review that left 4 comments |
Total time for pull request still awaiting merge: 2.7 business days
Fix sysFsReaddir
Fix issues in sysFsReaddir as reported in #12891 plus additional ones
Analysis assisted by Opus 5.
fixes #12891
Issues reported in #12891 already fixed upstream or not a bug:
-
sysFsReaddirnot breaking the loop: Fixed by commit a41d2e43f ("cellFsReaddir: Fix termination sequence", 2023-03-11), about four months after the report. -
CELL_ENOTMOUNTEDon/dev/urandom: Not a bug./dev/urandomis a Unix path with no mount point on the PS3 either, so the error is expected. The PolarSSL build inside the homebrew probably goes straight for the POSIX path instead of asking the console, so it was managed differently than on RPCS3.
List of fixes:
-
.and..are moved to the front regardless of the position the host returned them in, and the rest is sorted as before. - They are synthesised when the host lists neither. Win32 volume roots are the one directory that does not.
-
CELL_ENOENTis returned only when a stat does not see a non-reparse directory: an empty Win32 volume root fails the directory search exactly like a missing path, while a broken junction must stayENOENT. - sys_fs_readdir no longer dereferences the last entry of an empty listing.
- Split-file parts are listed only under the merged name:
.66600is renamed,.66601โ.66699are dropped, files only,/dev_hdd1unchanged.
Quick summary
I'm testing application that uses google drive api via curl. In the process of debugging app, i've noticed that some functions doesn't work the same as on real PS3 hardware. 1. the main issue: sysFsReaddir stops on the last available path and doesn't break a loop, while on PS3 it works as expected. 2. for curl there is no entropy source, yet it's not recorded in emulator log: - in RPCS3 logs you can find only "SYS: 'sys_fs_open' failed with 0x8001003a : CELL_ENOTMOUNTED, โ/dev/urandomโ " - while in curl logs from app there is: INFO: Failed - PolarSSL: ctr_drbg_init returned (-0x0034) CTR_DRBG - The entropy source failed
Details
On real PS3 this code is working as expected without introduced 'previousEntry' check. On RPCS3 'while' keeps looping on the last entry. Based on the result from PS3, i believe that on the next loop after last record read "entry.d_name" should be empty. ``` std::string previousEntry = ""; while (!sysFsReaddir(fd, &entry, &read) && strlen(entry.d_name) > 0) { debugPrintf("Reading directory (%s)....\n", entry.d_name); if(strcmp(previousEntry.c_str(),entry.d_name) == 0){ debugPrintf("Double reading resource (%s) - breaking loop.\n", entry.d_name); break; }
previousEntry = entry.d_name; if (strcmp(entry.d_name, ".") == 0 || strcmp(entry.d_name, "..") == 0) { continue; } .... }
Attach a log file
RPCS3.log.gz application_debug.log
Attach capture files for visual issues
No response
System configuration
๏ปฟRPCS3 v0.0.24-14316-7ae9b15b Alpha | master AMD Ryzen 7 4800H with Radeon Graphics | 16 Threads | 15.05 GiB RAM | TSC: 2.895GHz | AVX+ | FMA3 Operating system: POSIX, Name: Linux, Release: 5.18.12-arch1-1, Version: #1 SMP PREEMPT_DYNAMIC Fri, 15 Jul 2022 15:33:02 +0000 Qt version: Compiled against Qt 5.15.2 | Run-time uses Qt 5.15.5 Current Time: 2022-10-27T22:00:16
Other details
Emulator called via command: rpcs3 --verbose-curl
App installed as a package (.pkg)
App has enabled remote debugging on localhost udp port 18194
and can be logged via command ncat -u -l -p 18194 --no-shutdown -o debug.log
ps3-cloud-drive.pkg.tar.gz