diff options
author | Mateusz Guzik <mjg@FreeBSD.org> | 2021-05-22 19:37:53 +0000 |
---|---|---|
committer | Mateusz Guzik <mjg@FreeBSD.org> | 2021-05-22 19:41:19 +0000 |
commit | 154f0ecc10abdd3c23d233bf85e292011a130583 (patch) | |
tree | 4ce21d7a4fc2934107738fadc0fc1284d942e2dd /sys/kern | |
parent | a0842e69aa5f86d61c072544b540ef21b2015211 (diff) | |
download | src-154f0ecc10abdd3c23d233bf85e292011a130583.tar.gz src-154f0ecc10abdd3c23d233bf85e292011a130583.zip |
Fix tinderbox build after 1762f674ccb571e6 ktrace commit.
Diffstat (limited to 'sys/kern')
-rw-r--r-- | sys/kern/kern_exec.c | 6 | ||||
-rw-r--r-- | sys/kern/vfs_vnops.c | 2 |
2 files changed, 6 insertions, 2 deletions
diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index d9b9e1ae122b..709c1b0ff28a 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -390,7 +390,9 @@ do_execve(struct thread *td, struct image_args *args, struct mac *mac_p, static const char fexecv_proc_title[] = "(fexecv)"; imgp = &image_params; +#ifdef KTRACE kiop = NULL; +#endif /* * Lock the process and set the P_INEXEC flag to indicate that @@ -780,8 +782,6 @@ interpret: * we do not regain any tracing during a possible block. */ setsugid(p); - kiop = NULL; - #ifdef KTRACE kiop = ktrprocexec(p); #endif @@ -938,7 +938,9 @@ exec_fail: */ if (oldtextvp != NULL) vrele(oldtextvp); +#ifdef KTRACE ktr_io_params_free(kiop); +#endif pargs_drop(oldargs); pargs_drop(newargs); if (oldsigacts != NULL) diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index 9e45d1820eec..7f5275cf6b28 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -2371,11 +2371,13 @@ vn_rlimit_fsize(const struct vnode *vp, const struct uio *uio, if ((uoff_t)uio->uio_offset + uio->uio_resid < lim) return (0); +#ifdef KTRACE if (!ktr_write || ktr_filesize_limit_signal) { PROC_LOCK(td->td_proc); kern_psignal(td->td_proc, SIGXFSZ); PROC_UNLOCK(td->td_proc); } +#endif return (EFBIG); } |