Fix LBP1 user agent patching #9
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
HugeSpaceship/Patchwork!9
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "lbp1-race-condition-fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This fixes a race condition where LBP1 could copy the user agent elsewhere in memory before Patchwork writes to it, thus still sending the original one to the gameserver
Looks like this mainly affected RPCS3 and not real hardware
Has this been tested on RPCS3 and PS3? If not I can give it a shot.
@ -84,11 +84,27 @@ void patch_thread(uint64_t arg) {const sys_pid_t processPid = sys_process_getpid();uint8_t game = 0;int password_randomized = 1;This is a nitpick, but we're targeting C99, maybe best to use stdbool here?
I tested on RPCS3 only, couldn't test on PS3 since mine broke ¯\_(ツ)_/¯
@ -84,11 +84,27 @@ void patch_thread(uint64_t arg) {const sys_pid_t processPid = sys_process_getpid();uint8_t game = 0;int password_randomized = 1;This was already an int on upstream, so i just left it that way
But yeah, i think using stdbool here would be better
That's okay. I'll give it a shot on PS3 in a little bit.