mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-10 00:41:26 +12:00
sys_fs_fsync fix
This commit is contained in:
parent
e2478902c9
commit
e8d76ede14
1 changed files with 2 additions and 2 deletions
|
@ -1020,7 +1020,7 @@ error_code sys_fs_fdatasync(u32 fd)
|
||||||
|
|
||||||
const auto file = idm::get<lv2_fs_object, lv2_file>(fd);
|
const auto file = idm::get<lv2_fs_object, lv2_file>(fd);
|
||||||
|
|
||||||
if (!file)
|
if (!file || !(file->flags & CELL_FS_O_ACCMODE))
|
||||||
{
|
{
|
||||||
return CELL_EBADF;
|
return CELL_EBADF;
|
||||||
}
|
}
|
||||||
|
@ -1036,7 +1036,7 @@ error_code sys_fs_fsync(u32 fd)
|
||||||
|
|
||||||
const auto file = idm::get<lv2_fs_object, lv2_file>(fd);
|
const auto file = idm::get<lv2_fs_object, lv2_file>(fd);
|
||||||
|
|
||||||
if (!file)
|
if (!file || !(file->flags & CELL_FS_O_ACCMODE))
|
||||||
{
|
{
|
||||||
return CELL_EBADF;
|
return CELL_EBADF;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue