Open System Services Library Calls Reference Manual (G06.29+, H06.08+, J06.03+)
glob(3) OSS Library Calls Reference Manual
• If the application did not set the GLOB_DOOFFS flag in the first call to the glob( ) func-
tion, then the flag is not set in the second call.
• After the second call to the glob( ) function, the gl_padr field of the structure pointed to
by the pglob parameter points to a list containing the following:
— Zero or more null pointers, as specified by the GLOB_DOOFFS flag and
pglob->gl_offs
— Pointers to the pathnames that were in the pglob->gl_pathv list before the
second call to glob( ), in the same order as after the first call to glob( )
— Pointers to the new pathnames generated by the second call to glob( ), in the
specified order
• The count returned in pglob->gl_pathc is the total number of pathnames from the two
calls.
• If the count returned in pglob->gl_pathc is 0 (zero), the value of the pglob->gl_pathv
field is undefined.
• The application should not modify the pglob->gl_pathc or pglob->gl_pathv fields
between the two calls to glob( ).
It is the caller’s responsibility to create the structure pointed to by the pglob parameter. The
glob( ) function allocates other space as needed.
Use From the Guardian Environment
The glob( ) function is one of a set of functions that have the following effects when the first of
them is called from the Guardian environment:
• Two Guardian file system file numbers (not necessarily the next two available) are allo-
cated for the root directory and the current working directory. These file numbers cannot
be closed by calling the Guardian FILE_CLOSE_ procedure.
• The current working directory is assigned from the VOLUME attribute of the Guardian
environment =_DEFAULTS DEFINE.
• The use of static memory by the process increases slightly.
These effects occur only when the first of the set of functions is called. The effects are not cumu-
lative.
NOTES
If you use this function on the local / (slash) root directory, the action includes the /G and /E
directories. Actions appropriate for local OSS files under / often are not appropriate for local
Guardian files or for any files on other HP NonStop server nodes.
The UTILSGE environment variable that governs shell utility behavior can be used to test or
recommend whether use should include Guardian files or files on remote HP NonStop server
nodes. Note that UTILSGE settings are only advisory for functions; changing the variable value
does not affect function behavior. Refer to the environ(5) reference page either online or in the
Open System Services System Calls Reference Manual for more information about UTILSGE.
3−162 Hewlett-Packard Company 527187-017