This is an automated email from the git hooks/post-receive script. smcv pushed a commit to annotated tag 1.42d in repository iortcw.
commit c60a5f8f092eb08ca44af421372472dcedeb0670 Author: MAN-AT-ARMS <[email protected]> Date: Tue Mar 24 07:38:18 2015 -0400 All: Fix return values in nested system calls from QVMs --- MP/code/qcommon/vm_x86.c | 7 ++++--- SP/code/qcommon/vm_x86.c | 7 ++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/MP/code/qcommon/vm_x86.c b/MP/code/qcommon/vm_x86.c index 77aba05..3ec42ee 100644 --- a/MP/code/qcommon/vm_x86.c +++ b/MP/code/qcommon/vm_x86.c @@ -412,23 +412,24 @@ static void DoSyscall(void) if(vm_syscallNum < 0) { - int *data; + int *data, *ret; #if idx64 int index; intptr_t args[MAX_VMSYSCALL_ARGS]; #endif data = (int *) (savedVM->dataBase + vm_programStack + 4); + ret = &vm_opStackBase[vm_opStackOfs + 1]; #if idx64 args[0] = ~vm_syscallNum; for(index = 1; index < ARRAY_LEN(args); index++) args[index] = data[index]; - vm_opStackBase[vm_opStackOfs + 1] = savedVM->systemCall(args); + *ret = savedVM->systemCall(args); #else data[0] = ~vm_syscallNum; - vm_opStackBase[vm_opStackOfs + 1] = savedVM->systemCall((intptr_t *) data); + *ret = savedVM->systemCall((intptr_t *) data); #endif } else diff --git a/SP/code/qcommon/vm_x86.c b/SP/code/qcommon/vm_x86.c index 77aba05..3ec42ee 100644 --- a/SP/code/qcommon/vm_x86.c +++ b/SP/code/qcommon/vm_x86.c @@ -412,23 +412,24 @@ static void DoSyscall(void) if(vm_syscallNum < 0) { - int *data; + int *data, *ret; #if idx64 int index; intptr_t args[MAX_VMSYSCALL_ARGS]; #endif data = (int *) (savedVM->dataBase + vm_programStack + 4); + ret = &vm_opStackBase[vm_opStackOfs + 1]; #if idx64 args[0] = ~vm_syscallNum; for(index = 1; index < ARRAY_LEN(args); index++) args[index] = data[index]; - vm_opStackBase[vm_opStackOfs + 1] = savedVM->systemCall(args); + *ret = savedVM->systemCall(args); #else data[0] = ~vm_syscallNum; - vm_opStackBase[vm_opStackOfs + 1] = savedVM->systemCall((intptr_t *) data); + *ret = savedVM->systemCall((intptr_t *) data); #endif } else -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/iortcw.git _______________________________________________ Pkg-games-commits mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-games-commits

