Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Make gl_pathc, gl_matchc and gl_offs size_t in glob_t to match POSIX. | 2019-02-04 | 1 | -17/+16 | |
| | | | | This requires a libc major version bump. OK deraadt@ | ||||
* | Fix exponential CPU use with repeated '*' operators by changing '*' | 2017-05-08 | 1 | -21/+34 | |
| | | | | | handling to be interative instead of recursive. Fix by Yves Orton, ported to OpenBSD glob.c by Ray Lai. OK tb@ | ||||
* | Remove NULL-checks before free() and a few related dead assignments. | 2015-12-28 | 1 | -9/+5 | |
| | | | | ok and valuable input from millert@ | ||||
* | Use reentrant versions of getpw{nam,uid} and getgr{nam,gid} within | 2015-11-24 | 1 | -5/+9 | |
| | | | | | | | libc to avoid reusing the static buffers returned by the non-reentrant versions. Since this is inside libc we can use constants for the buffer sizes instead of having to call sysconf(). OK guenther@ deraadt@ | ||||
* | remove null check before free. from Michael McConville | 2015-09-14 | 1 | -5/+3 | |
| | | | | ok semarie | ||||
* | in glob() initialize the glob_t before the first failure check. | 2015-06-13 | 1 | -4/+4 | |
| | | | | | from j@pureftpd.org ok millert stsp | ||||
* | Include stdint.h, not limits.h to get SIZE_MAX. OK guenther@ | 2015-02-05 | 1 | -1/+2 | |
| | |||||
* | obvious realloc -> reallocarray conversion | 2014-10-08 | 1 | -3/+3 | |
| | |||||
* | Use PATH_MAX, NAME_MAX and LOGIN_NAME_MAX not MAXPATHNAMELEN, | 2013-09-30 | 1 | -15/+14 | |
| | | | | MAXNAMLEN or MAXLOGNAME where possible. OK deraadt@ | ||||
* | the glob stat limit is way too low. bump to 2048. | 2012-01-20 | 1 | -4/+4 | |
| | | | | | while here, failed stats should count against the limit too. ok deraadt sthen stsp | ||||
* | fix GLOB_KEEPSTAT without GLOB_NOSORT; the implicit sort was being | 2011-09-22 | 1 | -6/+44 | |
| | | | | | applied only to the gl_pathv vector and not the corresponding gl_statv array. reported in OpenSSH bz#1935; feedback and okay matthew@ | ||||
* | In glob(3), limit recursion during matching attempts. Similar to fnmatch fix. | 2011-09-20 | 1 | -5/+17 | |
| | | | | | Also collapse consecutive '*' (from NetBSD). ok miod deraadt | ||||
* | When the max number of items for a directory has reached GLOB_LIMIT_READDIR | 2011-05-12 | 1 | -2/+3 | |
| | | | | | | | | an error is returned but closedir() is not called. spotted and fix provided by Frank Denis obsd-tech@pureftpd.org ok otto@, millert@ | ||||
* | avoid some integer overflows mostly with GLOB_APPEND and GLOB_DOOFFS | 2011-01-12 | 1 | -4/+12 | |
| | | | | | | and sanity check arguments (these will be unnecessary when we switch struct glob members from being type into to size_t in the future); "looks ok" tedu@ feedback guenther@ | ||||
* | Extend GLOB_LIMIT to cover readdir and stat and bump the malloc limit | 2010-10-08 | 1 | -27/+63 | |
| | | | | | | | | | | | from ARG_MAX to 64K. Fixes glob-using programs (notably ftp) able to be triggered to hit resource limits. Idea from a similar NetBSD change, original problem reported by jasper@. ok millert tedu jasper | ||||
* | oops, don't free array before freeing members; spotted by dkrause@ | 2010-09-26 | 1 | -2/+2 | |
| | |||||
* | add a GLOB_KEEPSTAT option that retains a copy of the struct stat | 2010-09-24 | 1 | -14/+62 | |
| | | | | | | | | | | | information that is looked up while matching glob(3)s Keeping this information around can make a big difference when fetching it is expensive, e.g. in sftp which uses GLOB_ALTDIRFUNC feedback millert@ jmc@ "get it in before the libc crank" deraadt@ | ||||
* | remove unused variable | 2010-05-19 | 1 | -2/+1 | |
| | | | | ok nicm@ | ||||
* | Fix glob(3) to correctly return an error when its buffer space is | 2010-03-23 | 1 | -13/+11 | |
| | | | | | | | | | | exhausted and GLOB_BRACE is given. globexp2() was ignoring errors returned from lower levels. While here, change globexp2() to return its return value normally rather putting it in a int pointer then always returning 0. ok otto | ||||
* | replacing malloc/realloc dance, by only one realloc | 2009-11-21 | 1 | -3/+2 | |
| | | | | ok millert@ | ||||
* | Add missing braces. This is why we use braces for indented block that | 2009-02-18 | 1 | -2/+3 | |
| | | | | are more than a couple of lines... | ||||
* | POSIX character class support for fnmatch(3) and glob(3). OK deraadt@ | 2008-10-01 | 1 | -6/+72 | |
| | |||||
* | unused arg in internal static API | 2005-11-28 | 1 | -6/+6 | |
| | |||||
* | zap remaining rcsid. | 2005-08-08 | 1 | -8/+1 | |
| | | | | | | Kill old files that are no longer compiled. okay theo | ||||
* | Kill register and fix some whilespace goofs in a do {} while loop. | 2004-10-07 | 1 | -12/+11 | |
| | |||||
* | ansify function definitions and zap some `register' | 2004-05-18 | 1 | -67/+23 | |
| | | | | ok millert@ | ||||
* | protos | 2003-06-25 | 1 | -3/+3 | |
| | |||||
* | Remove the advertising clause in the UCB license which Berkeley | 2003-06-02 | 1 | -6/+2 | |
| | | | | rescinded 22 July 1999. Proofed by myself and Theo. | ||||
* | spelling; from Brian Poole <raj@cerias.purdue.edu> | 2002-06-14 | 1 | -2/+2 | |
| | |||||
* | try to use strlcpy and snprintf more; ok various | 2002-05-24 | 1 | -2/+2 | |
| | |||||
* | Manual cleanup of remaining userland __P use (excluding packages maintained outside the tree) | 2002-02-17 | 1 | -5/+5 | |
| | |||||
* | Part one of userland __P removal. Done with a simple regexp with some minor hand editing to make comments line up correctly. Another pass is forthcoming that handles the cases that could not be done automatically. | 2002-02-16 | 1 | -16/+16 | |
| | |||||
* | remove extra continue statements | 2001-04-05 | 1 | -11/+17 | |
| | |||||
* | use a len in g_Ctoc, easier code; freebsd | 2001-04-02 | 1 | -21/+18 | |
| | |||||
* | Fix some glob defects: | 2001-03-28 | 1 | -29/+56 | |
| | | | | | | | | o use MAXPATHLEN, not MAXPATHLEN + 1 o when manipulating static buffers, pass functions a pointer to the end of the buffer so we can avoid any overflows Work by Theo and myself. | ||||
* | must spec +1 in this one case... | 2001-03-28 | 1 | -2/+2 | |
| | |||||
* | avoid g_Ctoc() overflows; art@ ok | 2001-03-28 | 1 | -14/+26 | |
| | |||||
* | KNF | 2001-03-28 | 1 | -31/+12 | |
| | |||||
* | set gl_pathv to NULL after we free it; christos@netbsd.org | 2001-03-19 | 1 | -2/+5 | |
| | |||||
* | GLOB_LIMIT changes from christos | 2001-03-18 | 1 | -22/+38 | |
| | |||||
* | realloc repair | 1998-08-14 | 1 | -2/+5 | |
| | |||||
* | Add GLOB_NOESCAPE to turn off backslash escaping and make backslash escaping | 1998-01-31 | 1 | -5/+5 | |
| | | | | the default. For xpg4.2. | ||||
* | Make glob(3) XPG4.2 compliant. This means changing GLOB_ABEND to | 1997-09-01 | 1 | -10/+14 | |
| | | | | | GLOB_ABORT and defining GLOB_NOMATCH and GLOB_NOSYS (the latter is not used). | ||||
* | Different fix for buffer overflow. From Keith Bostic <bostic@bostic.com> | 1997-04-12 | 1 | -35/+39 | |
| | |||||
* | be careful in the non-setuid case too, what the heck | 1996-10-27 | 1 | -1/+4 | |
| | |||||
* | protect $HOME expansion; from das33@cornell.edu | 1996-09-11 | 1 | -2/+2 | |
| | |||||
* | Fix RCS ids | 1996-08-19 | 1 | -7/+1 | |
| | | | | Make sure everything uses {SYS,}LIBC_SCCS properly | ||||
* | initial import of NetBSD tree | 1995-10-18 | 1 | -0/+852 | |