In the previous sandbox implementation we read all sandboxed output
from standard output, and so all fake time writes were made to
standard output. Now we have a more sophisticated sandbox server
(see golang.org/x/playground/sandbox) that is capable of recording
both standard output and standard error, so allow fake time writes to
go to either file descriptor.
Change-Id: I79737deb06fd8e0f28910f21f41bd3dc1726781e
Reviewed-on: https://go-review.googlesource.com/2713
Reviewed-by: Minux Ma <minux@golang.org>
MOVL n+8(FP), DX
BSWAPL DX
MOVL DX, 12(SP)
- MOVL $1, DI // standard output
+ MOVL fd+0(FP), DI
MOVL SP, SI
MOVL $16, DX
NACL_SYSCALL(SYS_write)
// Write actual data.
- MOVL $1, DI // standard output
+ MOVL fd+0(FP), DI
MOVL p+4(FP), SI
MOVL n+8(FP), DX
NACL_SYSCALL(SYS_write)