freebsd-dev/sys/kern
Konstantin Belousov 15fb32c07d Do not underflow the buffer and then report the problem. Check for the
condition before the buffer write.
Also, since buflen is unsigned, previous check was ignored.

Reviewed by:	marcus
Tested by:	pho
2009-03-20 11:08:57 +00:00
..
bus_if.m
clock_if.m
cpufreq_if.m
device_if.m
genassym.sh
imgact_aout.c
imgact_elf32.c
imgact_elf64.c
imgact_elf.c Supply AT_EXECPATH auxinfo entry to the interpreter, both for native and 2009-03-17 12:53:28 +00:00
imgact_gzip.c
imgact_shell.c
inflate.c
init_main.c
init_sysent.c
kern_acct.c
kern_alq.c
kern_clock.c - Implement generic macros for producing KTR records that are compatible 2009-01-17 07:17:57 +00:00
kern_condvar.c Remove unused variables p' and unneeded assignments of rval'. 2009-02-26 13:00:13 +00:00
kern_conf.c Extract the no_poll() and vop_nopoll() code into the common routine 2009-03-06 15:35:37 +00:00
kern_cons.c Remove unneeded variable `ocn_mute'. 2009-02-26 13:01:45 +00:00
kern_context.c
kern_cpu.c
kern_cpuset.c
kern_ctf.c
kern_descrip.c Remove the printf's when the vnode to be exported for procstat is not a VDIR. 2009-02-14 21:55:09 +00:00
kern_dtrace.c
kern_environment.c
kern_event.c
kern_exec.c Supply AT_EXECPATH auxinfo entry to the interpreter, both for native and 2009-03-17 12:53:28 +00:00
kern_exit.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_fork.c
kern_idle.c
kern_intr.c
kern_jail.c Don't allow creating a socket with a protocol family that the current 2009-02-05 14:15:18 +00:00
kern_kthread.c
kern_ktr.c
kern_ktrace.c Add a new type of KTRACE record for sysctl(3) invocations. It uses the 2009-03-11 21:48:36 +00:00
kern_linker.c Scanning all the formats for binary translation of modules loading can 2009-02-10 15:50:19 +00:00
kern_lock.c - Wrap lock profiling state variables in #ifdef LOCK_PROFILING blocks. 2009-03-15 08:03:54 +00:00
kern_lockf.c
kern_malloc.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_mbuf.c Temporary workaround for the limitations of the mbuf flowid field: zero 2009-01-01 20:03:01 +00:00
kern_mib.c Mark most often used sysctl's as MPSAFE. 2009-01-28 19:58:05 +00:00
kern_module.c
kern_mtxpool.c
kern_mutex.c - Wrap lock profiling state variables in #ifdef LOCK_PROFILING blocks. 2009-03-15 08:03:54 +00:00
kern_ntptime.c
kern_osd.c Add support for methods to the OSD subsystem. Each object type has a 2009-02-21 11:15:38 +00:00
kern_physio.c
kern_pmc.c
kern_poll.c Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
kern_priv.c Reduce the verbosity of SDT trace points for DTrace by defining several 2009-03-03 17:15:05 +00:00
kern_proc.c - Add a function (fill_kinfo_aggregate()) which aggregates relevant 2009-02-18 21:52:13 +00:00
kern_prot.c Improve the consistency of MAC Framework and MAC policy entry point 2009-03-08 10:58:37 +00:00
kern_resource.c
kern_rmlock.c
kern_rwlock.c - Wrap lock profiling state variables in #ifdef LOCK_PROFILING blocks. 2009-03-15 08:03:54 +00:00
kern_sdt.c
kern_sema.c
kern_shutdown.c
kern_sig.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_subr.c
kern_switch.c
kern_sx.c - Wrap lock profiling state variables in #ifdef LOCK_PROFILING blocks. 2009-03-15 08:03:54 +00:00
kern_synch.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_syscalls.c
kern_sysctl.c Add a new type of KTRACE record for sysctl(3) invocations. It uses the 2009-03-11 21:48:36 +00:00
kern_tc.c By default, don't compile in counters of calls to various time 2009-03-08 22:19:28 +00:00
kern_thr.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_thread.c - Implement a new mechanism for resetting lock profiling. We now 2009-03-15 06:41:47 +00:00
kern_time.c Remove even more unneeded variable assignments. 2009-02-26 15:51:54 +00:00
kern_timeout.c Add explicit static DTrace tracing to the callout mechanism, capturing 2009-01-24 10:22:49 +00:00
kern_umtx.c 1) Check NULL pointer before calling umtx_pi_adjust_locked(), this avoids 2009-03-13 06:06:20 +00:00
kern_uuid.c For all files including net/vnet.h directly include opt_route.h and 2009-02-27 14:12:05 +00:00
kern_vimage.c
kern_xxx.c Fix compilation. Also move ogetkerninfo() to kern_xxx.c. 2008-12-29 19:24:00 +00:00
ksched.c
link_elf_obj.c Scanning all the formats for binary translation of modules loading can 2009-02-10 15:50:19 +00:00
link_elf.c Scanning all the formats for binary translation of modules loading can 2009-02-10 15:50:19 +00:00
linker_if.m
Make.tags.inc
Makefile
makesyscalls.sh
md4c.c
md5c.c
p1003_1b.c
posix4_mib.c
sched_4bsd.c - Use __XSTRING where I want the define to be expanded. This resulted in 2009-01-25 07:35:10 +00:00
sched_ule.c - Fix an error that occurs when mp_ncpu is an odd number. steal_thresh 2009-03-14 11:41:36 +00:00
serdev_if.m
stack_protector.c
subr_acl_posix1e.c
subr_autoconf.c Prefer ANSI function definitions to K&R ones. 2009-02-03 07:52:07 +00:00
subr_blist.c
subr_bufring.c
subr_bus.c Minor nits notice by jhb@ 2009-03-11 08:19:31 +00:00
subr_clist.c Remove a stale comment from the clists code. 2009-02-09 11:27:56 +00:00
subr_clock.c
subr_devstat.c Use NULL in preference to 0 in pointer contexts. 2009-02-03 07:54:42 +00:00
subr_disk.c Clarify and reimplement the bioq API so that bioq_disksort() has 2009-02-13 11:36:32 +00:00
subr_eventhandler.c
subr_fattime.c
subr_firmware.c Use NULL in preference to 0 for pointers. 2009-02-03 07:51:11 +00:00
subr_hints.c
subr_kdb.c
subr_kobj.c Use NULL in preference to 0 in pointer contexts. 2009-02-03 07:54:42 +00:00
subr_lock.c - Implement a new mechanism for resetting lock profiling. We now 2009-03-15 06:41:47 +00:00
subr_log.c
subr_mbpool.c
subr_mchain.c
subr_module.c
subr_msgbuf.c
subr_param.c Change the sysctls for maxbcache and maxswzone from int to long. I missed 2009-03-12 17:23:02 +00:00
subr_pcpu.c - Implement generic macros for producing KTR records that are compatible 2009-01-17 07:17:57 +00:00
subr_power.c
subr_prf.c Remove redundant code in printf() and vprintf(). 2009-02-27 13:28:54 +00:00
subr_prof.c Use ANSI function definition for profil. 2009-02-03 07:52:36 +00:00
subr_rman.c rman_debug should be static, so make it static. 2009-02-03 07:53:08 +00:00
subr_rtc.c int foo(void) is the proper ANSI function definition when there's no 2009-02-03 07:50:01 +00:00
subr_sbuf.c
subr_scanf.c
subr_sleepqueue.c
subr_smp.c Initial suspend/resume support for amd64. 2009-03-17 00:48:11 +00:00
subr_stack.c
subr_taskqueue.c Remove semicolon left in the last commit 2009-02-13 18:51:39 +00:00
subr_trap.c
subr_turnstile.c
subr_unit.c
subr_witness.c Decompose the global UNIX domain sockets rwlock into two different 2009-03-08 21:48:29 +00:00
sys_generic.c When writing out updated pollfd records when returning from 2009-03-11 22:00:03 +00:00
sys_pipe.c - Make maxpipekva a signed long rather than an unsigned long as overflow 2009-03-10 21:28:43 +00:00
sys_process.c Use the p_sysent->sv_flags flag SV_ILP32 to detect 32bit process 2009-03-02 18:43:50 +00:00
sys_socket.c
syscalls.c
syscalls.master
systrace_args.c
sysv_ipc.c
sysv_msg.c
sysv_sem.c Lock the semaphore identifier lock during semaphore initialization to 2009-01-15 12:15:46 +00:00
sysv_shm.c Systematically use vm_size_t to specify the size of the segment for VM KPI. 2009-03-05 11:45:42 +00:00
tty_compat.c
tty_info.c Replace bcopy() calls inside the TTY layer with memcpy()/strlcpy(). 2009-02-28 14:20:26 +00:00
tty_inq.c Use unsigned longs for the TTY's sysctl stats. 2009-02-26 10:28:32 +00:00
tty_outq.c Use unsigned longs for the TTY's sysctl stats. 2009-02-26 10:28:32 +00:00
tty_pts.c Improve my previous changes to the TTY code: also remove memcpy(). 2009-03-01 09:50:13 +00:00
tty_pty.c Don't use PTY name as format string, even though it isn't insecure here. 2009-02-26 10:14:10 +00:00
tty_tty.c
tty_ttydisc.c Use unsigned longs for the TTY's sysctl stats. 2009-02-26 10:28:32 +00:00
tty.c Improve my previous changes to the TTY code: also remove memcpy(). 2009-03-01 09:50:13 +00:00
uipc_accf.c
uipc_cow.c Extend the struct vm_page wire_count to u_int to avoid the overflow 2009-01-03 13:24:08 +00:00
uipc_debug.c Remove extra 'comma = 0' in socket state printing code, which otherwise 2009-02-09 18:19:58 +00:00
uipc_domain.c Remove Giant locking from domains list. 2009-01-04 19:22:53 +00:00
uipc_mbuf2.c
uipc_mbuf.c Teach m_copyback() to use trailing space of the last mbuf in chain. 2009-01-18 20:19:55 +00:00
uipc_mqueue.c
uipc_sem.c Ensure that the semaphore value is re-checked after sem_lock 2009-03-12 10:36:39 +00:00
uipc_shm.c
uipc_sockbuf.c
uipc_socket.c Don't allow creating a socket with a protocol family that the current 2009-02-05 14:15:18 +00:00
uipc_syscalls.c
uipc_usrreq.c Decompose the global UNIX domain sockets rwlock into two different 2009-03-08 21:48:29 +00:00
vfs_acl.c
vfs_aio.c Use the correct type for the timeout parameter to the 32-bit 2009-01-23 13:23:17 +00:00
vfs_bio.c Fix an old-standing bug that crept in along the several revisions: 2009-03-17 16:30:49 +00:00
vfs_cache.c Do not underflow the buffer and then report the problem. Check for the 2009-03-20 11:08:57 +00:00
vfs_cluster.c
vfs_default.c Add a default implementation for VOP_VPTOCNP(9) which scans the parent 2009-03-08 19:05:53 +00:00
vfs_export.c
vfs_extattr.c Remove 'uio' argument from MAC Framework and MAC policy entry points for 2009-03-08 12:32:06 +00:00
vfs_hash.c
vfs_init.c Expand the scope of the sysctllock sx lock to protect the sysctl tree itself. 2009-02-06 14:51:32 +00:00
vfs_lookup.c Gah, fix the code to match the comment. For non-open lookups use a 2009-03-11 14:39:55 +00:00
vfs_mount.c Extend the "vfsopt" mount options for more general use. Make struct 2009-03-02 23:26:30 +00:00
vfs_subr.c Change vfs_busy to wait until an outcome of pending unmount 2009-03-02 20:51:39 +00:00
vfs_syscalls.c Don't make Linux stat() open character devices to resolve its name. 2009-02-20 13:05:29 +00:00
vfs_vnops.c Add a new internal mount flag (MNTK_EXTENDED_SHARED) to indicate that a 2009-03-11 14:13:47 +00:00
vnode_if.src Add a new internal mount flag (MNTK_EXTENDED_SHARED) to indicate that a 2009-03-11 14:13:47 +00:00