mirror of
https://github.com/ptitSeb/box86.git
synced 2024-11-27 11:54:50 +08:00
Fixed a potential issue with stack overwritten on sigaction call
This commit is contained in:
parent
5cdd2d4947
commit
0e9a422335
@ -1072,7 +1072,7 @@ int EXPORT my_syscall_sigaction(x86emu_t* emu, int signum, const x86_sigaction_r
|
||||
ret = sigaction(signum, act?&newact:NULL, oldact?&old:NULL);
|
||||
if(oldact && ret==0) {
|
||||
oldact->sa_flags = old.sa_flags;
|
||||
oldact->sa_mask = old.sa_mask;
|
||||
memcpy(&oldact->sa_mask, &old.sa_mask, (sigsetsize>8)?8:sigsetsize);
|
||||
if(old.sa_flags & 0x04)
|
||||
oldact->_u._sa_sigaction = old.sa_sigaction; //TODO should wrap...
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user