1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-25 12:12:50 +01:00
Commit Graph

190 Commits

Author SHA1 Message Date
Elad Ashkenazi
a2dcbb9c13 Replace src_loc with std::soource_location 2024-05-21 14:19:12 +03:00
Elad Ashkenazi
91a54c11eb Savestates: Fixup file write 2024-05-05 06:57:11 +03:00
Eladash
88ba3c47c2 ELF.h: Avoid using seek operations 2024-02-16 10:42:57 +02:00
Megamouse
0d1fbfb755 VFS: Fix some potential .back() segfaults 2024-01-25 17:03:58 +01:00
Steveice10
3ef48cbdd5 rpcs3qt: Add macOS support to the updater. 2024-01-24 09:44:56 +01:00
Megamouse
50fcec63e0 fs: fix get_executable_dir 2024-01-21 00:11:16 +01:00
Megamouse
8edd7d54cf fs: fix warning. fix size argument in report_fatal_error 2024-01-20 21:59:02 +01:00
Steveice10
9c354ee269
Utilities: Add support for portable user directory. (#15064) 2024-01-20 10:04:25 +02:00
Megamouse
3d974eed03 fs: move buf from stack to heap to silence VS warning 2024-01-14 06:40:35 +01:00
Megamouse
329b58c8cd fs: remove duplicate to_utf8 function 2024-01-14 06:40:35 +01:00
Megamouse
59c58aa3cf fix some warnings 2023-12-30 19:07:35 +01:00
Eladash
f60bdbaece Savestates: Compressed state files 2023-11-27 12:36:17 +02:00
Eladash
66d01b688c Savestates: Implement initial RAM ventilation system 2023-11-10 08:45:49 +02:00
Megamouse
6bc7d7c698 fs::utime: fallback to 01/01/1980 00:00:00 if the date is too low 2023-09-04 10:07:23 +03:00
Eladash
66b6bae596 Win32/File.cpp: Avoid potential race in concurrent writes
Uninitialized data is better than overwritten data. Affects SPU Cache (unprotected writes).
2023-09-02 12:31:11 +03:00
oltolm
bc40b61ef1 rename fs::stat to fs::get_stat 2023-07-25 12:15:08 +03:00
Eladash
9291e2777d File.h: Implement fs::error::xdev 2023-07-21 12:27:35 +03:00
Eladash
eecadab387 Implement fs::file::get_id()
File descripor ID with 2 provided ways to compare between them:
1. is_mirror_of():
 Test if identical:
  For example: when LHS writes one byte to a file at X offset, RHS file be able to read that exact byte at X offset)

2. is_coherent_with():
 Test if both files point to the same file:
  For example: if a file descriptor pointing to the complete file exists and is being truncated to 0 bytes from non-
  -zero size state: this has to affect both RHS and LHS files.
2023-07-17 08:09:09 +03:00
oltolm
0c94606fcf
Make compile with msvc, clang and gcc on Windows 2023-07-11 21:40:30 +03:00
brian218
cf4ae38699 sys_fs: Implemented get_normalized_path() 2023-06-25 09:08:20 +02:00
Eladash
09f83e48ff fs: Add get_parent_dir_view
string view version of the argument path, use with care.
2023-06-24 12:00:04 +03:00
Eladash
bcbce5dd48 File.cpp: revert get_parent_dir change 2023-06-24 12:00:04 +03:00
Megamouse
635fed0427 fs/linux: fix potential copy_file issue
sendfile is meant to be run in a loop, since there is no guarantee that a single call copies all the data.
The current implementation may lead to corrupt files on linux.
2023-06-12 15:59:32 +03:00
brian218
a131a41874 Fixed a bug in fs::get_parent_dir() 2023-06-05 20:15:43 +02:00
brian218
6a570ae57e sys_fs: Implemented sys_fs_mount(prot=1) read-only mounting & fixed up some operation and permission checks 2023-06-05 13:51:54 +03:00
Megamouse
92ae57c9ee Windows: log more descriptive errors 2023-03-04 18:34:56 +01:00
Elad Ashkenazi
382a27cb2f
Allow to cancel dir size calculation (#13134) 2022-12-30 09:34:35 +01:00
Nekotekina
eeda958f33 fs: fix read/read_at/write (Unix)
It's known that too huge read can require multiple syscalls.
2022-12-29 16:19:54 +03:00
Nekotekina
2f9cac8d18 fs: implement file::read_at
Reads from the given offset; does not seek; thread-safe.
2022-12-29 16:19:54 +03:00
Elad Ashkenazi
ad3ea966cb
Add RPCS3/games/ for automatic games detection, support PSN games outside HDD0 (#12982)
* SFO: Do not load PARAM.SFO with illegal TITLE_ID
* Add support for PSN games outside HDD0
* Add RPCS3/games/ for automatic game detection
2022-12-02 13:18:07 +03:00
Eladash
149c593d89 Make fs::get_parent_dir/fs::pending_file use string_view as argument 2022-06-27 15:03:39 +03:00
Eladash
1088375b38 Wipe clean VSH's temporary directory of choice at boot 2022-05-21 10:57:12 +03:00
Eladash
781b2b4548
Implement fs::isfile (#11447) 2022-01-29 22:10:48 +03:00
MSuih
f526027778
Revert recent file system changes (#11370)
* Revert "FS: use std::filesystem::u8path"

This reverts commit cd016be86e.

* Revert "VFS: fix missing path deliminators"

This reverts commit 84753db574.

* Revert "Bugfix of Emulator::Load disc path searching"

This reverts commit b9179de288.

* Revert "fs: Reimplement path resolving using std::filesystem::weakly_canonical"

This reverts commit 0c4b2ff06b.
2022-01-13 07:24:04 +03:00
Megamouse
cd016be86e FS: use std::filesystem::u8path 2022-01-13 00:07:25 +03:00
Eladash
0c4b2ff06b fs: Reimplement path resolving using std::filesystem::weakly_canonical 2022-01-12 03:37:39 +03:00
Nekotekina
6b40d69a8f Introduce coroutine support (util/coro.hpp)
Implement coroutine types `lazy` and `generator` in stx namespace.
Implement fs::list_dir_recursively.
2021-12-07 13:04:10 +03:00
Eladash
f16949c292
fs::file: always use strict reading mode for large reads (#11206) 2021-12-01 19:09:07 +03:00
Eladash
9afa960979 Fix possible fs::create_path recursion overflow 2021-10-22 15:37:47 +03:00
Eladash
73bdf7481e Emu: Fix disc game move from hdd0/game 2021-09-17 22:15:48 +02:00
Eladash
66368debf8 Win32 FS: Implement support for large reads/writes 2021-07-16 18:48:20 +03:00
Nekotekina
3c614d95b8 fs: alternative fs::pending_file implementation (Win32)
Use MOVEFILE_WRITE_THROUGH instead of sync() on commit().
2021-06-20 22:08:24 +03:00
Nekotekina
160b131de3 types.hpp: implement smin, smax, amin, amax
Rewritten the following global utility constants:
`umax` returns max number, restricted to unsigned.
`smax` returns max signed number, restricted to integrals.
`smin` returns min signed number, restricted to signed.
`amin` returns smin or zero, less restricted.
`amax` returns smax or umax, less restricted.

Fix operators == and <=> for synthesized rel-ops.
2021-05-22 12:10:57 +03:00
Nekotekina
e24ada37bf fs: implement fs::get_temp_dir() (Win32)
Trying to workaround issues with sparse files (#10231)
2021-05-05 19:38:36 +03:00
Nekotekina
a211895e28 shared_ptr.hpp: use for fs::virtual_device
Add new constructors for single_ptr and shared_ptr.
Change virtual device prefix format.
2021-04-15 17:26:47 +03:00
Megamouse
a16d8ba3ea More random changes 2021-04-11 14:01:51 +03:00
Eladash
11824b3916 Win32 FS: Improve fs::create_dir 2021-04-10 23:51:49 +03:00
Eladash
49c5ce30cc Emulation: Fix boot path resolving
* Fix /dev_flash executables path arg. (/host_root is wrong for it)
* Fix usage of /host_root for homebrew applications when it is not mounted, use /app_home.
* Fix path source detection. (don't get fooled by path slashes repetitions, symlinks, '.', ".." and ('\' on Windows))
* Unescape tail of /dev_hdd0 paths.
2021-04-08 23:57:00 +03:00
Nekotekina
95725bf7fc Add -Werror=missing-noreturn (GCC, clang)
May be useful to diagnose functions which fail assertions unconditionally.
2021-04-08 10:29:47 +03:00
Nekotekina
2212a131ef Fix some -Weffc++ warnings (part 1) 2021-03-31 11:27:09 +03:00