Provides functions and structures used to find path names matching a pattern and release the memory that was applied for during the search.
In the pglob parameter of the glob() function, reserve a string that has a length of pglob->gl_offs and ends with \0 at the beginning of the string list in pglob->pathv. That is, the newly matched string is appended to a position where the distance from the beginning of pglob->pathv is the length of pglob->gl_offs.
Append the results of this call to the results returned by a previous call to glob().
Carry out tilde expansion. If a tilde (~) is the only character in the pattern, or an initial tilde is followed immediately by a slash (/), then the home directory of the caller is substituted for the tilde.
Frees allocated memory from a call to glob().