Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F146933886
D14868.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
D14868.id.diff
View Options
Index: head/sys/compat/freebsd32/freebsd32_misc.c
===================================================================
--- head/sys/compat/freebsd32/freebsd32_misc.c
+++ head/sys/compat/freebsd32/freebsd32_misc.c
@@ -3285,6 +3285,7 @@
CP(*stat, *stat32, size);
bcopy(&stat->pathname[0], &stat32->pathname[0],
sizeof(stat->pathname));
+ stat32->version = version;
error = copyout(stat32, uap->stat, version);
}
free(stat, M_TEMP);
Index: head/sys/dev/pci/pci_user.c
===================================================================
--- head/sys/dev/pci/pci_user.c
+++ head/sys/dev/pci/pci_user.c
@@ -770,6 +770,8 @@
#ifdef PRE7_COMPAT
#ifdef COMPAT_FREEBSD32
if (cmd == PCIOCGETCONF_OLD32) {
+ memset(&conf_old32, 0,
+ sizeof(conf_old32));
conf_old32.pc_sel.pc_bus =
dinfo->conf.pc_sel.pc_bus;
conf_old32.pc_sel.pc_dev =
@@ -803,6 +805,7 @@
} else
#endif /* COMPAT_FREEBSD32 */
if (cmd == PCIOCGETCONF_OLD) {
+ memset(&conf_old, 0, sizeof(conf_old));
conf_old.pc_sel.pc_bus =
dinfo->conf.pc_sel.pc_bus;
conf_old.pc_sel.pc_dev =
Index: head/sys/kern/kern_ntptime.c
===================================================================
--- head/sys/kern/kern_ntptime.c
+++ head/sys/kern/kern_ntptime.c
@@ -285,6 +285,8 @@
{
struct ntptimeval ntv;
+ memset(&ntv, 0, sizeof(ntv));
+
NTP_LOCK();
ntp_gettime1(&ntv);
NTP_UNLOCK();
Index: head/sys/kern/kern_sig.c
===================================================================
--- head/sys/kern/kern_sig.c
+++ head/sys/kern/kern_sig.c
@@ -694,8 +694,8 @@
ps = p->p_sigacts;
mtx_lock(&ps->ps_mtx);
if (oact) {
+ memset(oact, 0, sizeof(*oact));
oact->sa_mask = ps->ps_catchmask[_SIG_IDX(sig)];
- oact->sa_flags = 0;
if (SIGISMEMBER(ps->ps_sigonstack, sig))
oact->sa_flags |= SA_ONSTACK;
if (!SIGISMEMBER(ps->ps_sigintr, sig))
Index: head/sys/kern/sysv_shm.c
===================================================================
--- head/sys/kern/sysv_shm.c
+++ head/sys/kern/sysv_shm.c
@@ -1471,6 +1471,7 @@
break;
case SHM_STAT:
case IPC_STAT:
+ memset(&u32.shmid_ds32, 0, sizeof(u32.shmid_ds32));
freebsd32_ipcperm_old_out(&u.shmid_ds.shm_perm,
&u32.shmid_ds32.shm_perm);
if (u.shmid_ds.shm_segsz > INT32_MAX)
@@ -1634,6 +1635,7 @@
/* Cases in which we need to copyout */
switch (uap->cmd) {
case IPC_STAT:
+ memset(&old, 0, sizeof(old));
ipcperm_new2old(&buf.shm_perm, &old.shm_perm);
if (buf.shm_segsz > INT_MAX)
old.shm_segsz = INT_MAX;
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Mar 7, 9:50 PM (7 h, 49 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
29382439
Default Alt Text
D14868.id.diff (2 KB)
Attached To
Mode
D14868: Fix several leaks of kernel stack data through paddings.
Attached
Detach File
Event Timeline
Log In to Comment