Skip to content

Conversation

@Megamouse
Copy link
Contributor

@Megamouse Megamouse commented Jun 8, 2023

sendfile/sendfile64 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.

@elad335
Copy link
Contributor

elad335 commented Jun 9, 2023

maybe sendfile indeed needs a loop but sendfile64 does not? I don't find any information the limitation of sendfile64.

@ghost
Copy link

ghost commented Jun 11, 2023

Maybe there is no need to use sendfile64, actually, it seems Linux-specific

@Megamouse
Copy link
Contributor Author

you mean because of this?
"The glibc sendfile() wrapper function transparently deals with the kernel differences."

@ghost
Copy link

ghost commented Jun 11, 2023

I think so, yes

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.
@Megamouse Megamouse force-pushed the sendfile branch 2 times, most recently from e463c19 to 0dc7ca7 Compare June 11, 2023 14:25
@ghost ghost merged commit 635fed0 into RPCS3:master Jun 12, 2023
@Megamouse Megamouse deleted the sendfile branch June 12, 2023 17:34
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants