libc - Fix security issue in globbing code
authorMatthias Schmidt <matthias@dragonflybsd.org>
Wed, 20 Oct 2010 17:08:20 +0000 (19:08 +0200)
committerMatthias Schmidt <matthias@dragonflybsd.org>
Wed, 20 Oct 2010 17:08:20 +0000 (19:08 +0200)
commitbc8e0f77eec9ca5181609828450dc2dbbb475be8
tree5e3e17fe93f8adbf4d0198187af8c2114c533685
parentfb12e9a5b3acecedcc888a0ad723826f184c8183
libc - Fix security issue in globbing code

There is a report about memory exhaustion in CVE-2010-2632 which also
affected us.  This patch, adopted from NetBSD, fixes the issue.

Tested-by: thomas@ and me
OK: dillon@
lib/libc/gen/glob.c