diff options
author | Mike Frysinger <vapier@gentoo.org> | 2015-09-20 03:27:34 -0400 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2015-09-20 03:27:34 -0400 |
commit | efb6ac30fb0d39cbd5f801c6d251b14ed5f5a7d6 (patch) | |
tree | b8b054c1663a18412ee78bb0367871b22f5c78b0 /libsandbox/libsandbox.c | |
parent | libsandbox: fix handling of dangling symlinks (diff) | |
download | sandbox-efb6ac30fb0d39cbd5f801c6d251b14ed5f5a7d6.tar.gz sandbox-efb6ac30fb0d39cbd5f801c6d251b14ed5f5a7d6.tar.bz2 sandbox-efb6ac30fb0d39cbd5f801c6d251b14ed5f5a7d6.zip |
libsandbox: improve debugging output a bit
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'libsandbox/libsandbox.c')
-rw-r--r-- | libsandbox/libsandbox.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libsandbox/libsandbox.c b/libsandbox/libsandbox.c index 57be731..1d9fa04 100644 --- a/libsandbox/libsandbox.c +++ b/libsandbox/libsandbox.c @@ -912,6 +912,8 @@ static int check_syscall(sbcontext_t *sbcontext, int sb_nr, const char *func, resolved_path = resolve_path(file, 1); if (!absolute_path || !resolved_path) goto error; + sb_debug_dyn("absolute_path: %s\n", absolute_path); + sb_debug_dyn("resolved_path: %s\n", resolved_path); verbose = is_env_set_on(ENV_SANDBOX_VERBOSE, &set); if (set) @@ -1098,9 +1100,9 @@ bool before_syscall_open_char(int dirfd, int sb_nr, const char *func, const char if ((*mode == 'r') && ((0 == (strcmp(mode, "r"))) || /* The strspn accept args are known non-writable modifiers */ (strlen(mode+1) == strspn(mode+1, "xbtmce")))) - sb_nr = SB_NR_OPEN_RD, ext_func = "open_rd"; + sb_nr = SB_NR_OPEN_RD, ext_func = "fopen_rd"; else - sb_nr = SB_NR_OPEN_WR, ext_func = "open_wr"; + sb_nr = SB_NR_OPEN_WR, ext_func = "fopen_wr"; return before_syscall(dirfd, sb_nr, ext_func, file, 0); } |