diff options
author | midipix <writeonce@midipix.org> | 2018-08-05 04:48:56 -0400 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2018-08-05 04:52:35 -0400 |
commit | f36276f52194fd50cee65e76b372653b1cd71b06 (patch) | |
tree | 16bbc5c5ae22b86f002123bf22a276fc82e4288e | |
parent | 4ce9ee82745459202f18e507e7b1ead355a41ff1 (diff) | |
download | ntux-f36276f52194fd50cee65e76b372653b1cd71b06.tar.bz2 ntux-f36276f52194fd50cee65e76b372653b1cd71b06.tar.xz |
ntux_cmd_strace(): integrated the driver's fdctx.
-rw-r--r-- | src/cmds/ntux_cmd_strace.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cmds/ntux_cmd_strace.c b/src/cmds/ntux_cmd_strace.c index b434189..4f23e39 100644 --- a/src/cmds/ntux_cmd_strace.c +++ b/src/cmds/ntux_cmd_strace.c @@ -19,8 +19,8 @@ int ntux_cmd_strace(const struct ntux_driver_ctx * dctx) { - int32_t status; int ret; + int32_t status; pid_t pid; const char ** argv; const char ** envp; @@ -46,7 +46,9 @@ int ntux_cmd_strace(const struct ntux_driver_ctx * dctx) /* fdlog */ if (logfile) { - if ((fdlog[1] = __sys_open(logfile,O_CREAT|O_TRUNC|O_WRONLY,0)) < 0) + if ((fdlog[1] = __sys_openat( + ntux_driver_fdcwd(dctx), + logfile,O_CREAT|O_TRUNC|O_WRONLY,0)) < 0) if (ntux_errno_set(dctx,fdlog[1])) return NTUX_SYSTEM_ERROR(dctx); } else { |