diff options
author | Bob Beck <beck@cvs.openbsd.org> | 2015-12-11 22:34:35 +0000 |
---|---|---|
committer | Bob Beck <beck@cvs.openbsd.org> | 2015-12-11 22:34:35 +0000 |
commit | 70fb4b7bbff869680b7eb0a7a7f198e4cb0ecdcb (patch) | |
tree | eb7b24fe259167ec79f67c4ee1210c41341722ee /sys/tmpfs | |
parent | 7ac23043e56379b2dbd40f5c08b73bb3667eb26c (diff) |
fix nde structure initialization, noticed in netbsd pr 50381 by mmcc@
by ensuring the structure is zeroed when allocated from the pool
ok mmcc@, stsp@
Diffstat (limited to 'sys/tmpfs')
-rw-r--r-- | sys/tmpfs/tmpfs_mem.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/tmpfs/tmpfs_mem.c b/sys/tmpfs/tmpfs_mem.c index aaa321d9570..3471de191b3 100644 --- a/sys/tmpfs/tmpfs_mem.c +++ b/sys/tmpfs/tmpfs_mem.c @@ -1,4 +1,4 @@ -/* $OpenBSD: tmpfs_mem.c,v 1.7 2015/03/14 03:38:52 jsg Exp $ */ +/* $OpenBSD: tmpfs_mem.c,v 1.8 2015/12/11 22:34:34 beck Exp $ */ /* $NetBSD: tmpfs_mem.c,v 1.4 2011/05/24 01:09:47 rmind Exp $ */ /* @@ -151,7 +151,7 @@ tmpfs_dirent_get(struct tmpfs_mount *mp) if (!tmpfs_mem_incr(mp, sizeof(struct tmpfs_dirent))) { return NULL; } - return pool_get(&tmpfs_dirent_pool, PR_WAITOK); + return pool_get(&tmpfs_dirent_pool, PR_ZERO|PR_WAITOK); } void |