]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
As the comment says, close() frees the variable, record. So we obtain
authorXin LI <delphij@FreeBSD.org>
Thu, 14 May 2009 23:09:33 +0000 (23:09 +0000)
committerXin LI <delphij@FreeBSD.org>
Thu, 14 May 2009 23:09:33 +0000 (23:09 +0000)
commit718d3b2852771dc978d19eb0875988d375003e4b
tree601ad1c215db37453905f6f5afa29a3a353fe761
parent9fe569d8f96e06bca0ca3d21c16c2a714b31a858
As the comment says, close() frees the variable, record.  So we obtain
the length by evaluating the value from the copy, cbuf instead.  This
fixes a crash caused by previous commit (use-after-free)

Submitted by: Dimitry Andric <dimitry andric com>
Pointy hat to: delphij
lib/libc/gen/getcap.c