vx32

Local 9vx git repository for patches.
git clone git://r-36.net/vx32
Log | Files | Refs

commit d8ca118560a6bbcfc61884ea0ea88756dad39432
parent 1c5e7e4c2a61dc3c289d807c7506d4cbef12244f
Author: rminnich@xcpu2 <none@none>
Date:   Sun, 21 Mar 2010 19:17:07 -0700

fd2path is now right.

Diffstat:
src/9vx/trap.c | 13++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)

diff --git a/src/9vx/trap.c b/src/9vx/trap.c @@ -339,9 +339,9 @@ syscallprint(Ureg *ureg) break; } case FD2PATH: - up->syscalltrace = smprint("%d [%s] %s %#ux %d", + up->syscalltrace = smprint("%d [%s] %s %#ux %d %#ux %d", up->pid, up->text, - sysctab[ureg->ax], sp[0], sp[1]); + sysctab[ureg->ax], sp[0], sp[1], sp[2], sp[3]); break; case BRK_: up->syscalltrace = smprint("%d [%s] %s %#ux %08ux %08ux %08ux %08uxh", @@ -522,7 +522,6 @@ retprint(Ureg *ureg, int syscallno) case _WRITE: case PIPE: case CREATE: - case FD2PATH: case BRK_: case REMOVE: case _WSTAT: @@ -560,6 +559,14 @@ retprint(Ureg *ureg, int syscallno) else up->syscalltrace = smprint("= %d\n", ureg->ax); break; + case FD2PATH: + if(ureg->ax == -1) + up->syscalltrace = smprint("= %s\n", up->syserrstr); + else { + char *s = uvalidaddr(up->s.args[1], up->s.args[2], 0); + up->syscalltrace = smprint("= %#ux='%s'\n", ureg->ax, s); + } + break; case PREAD: if(ureg->ax == -1) up->syscalltrace = smprint("= %s\n", up->syserrstr);