Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 1
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 1
Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 8
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 8
Resolve a pathname
#include <stdlib.h>
char * realpath( const char * pathname,
char * resolved_name );
- pathname
- The path name that you want to resolve.
- resolved_name
- A pointer to a buffer where the function can store the resolved name.
libc
Use the -l c option to
qcc
to link against this library.
This library is usually included automatically.
The realpath() function resolves all symbolic links, extra
slash (/) characters
and references to /./ and /../ in pathname,
and copies the resulting
absolute pathname into the memory referenced by resolved_name.
To determine the size of the buffer pointed to by
resolved_name, call
fpathconf()
or
pathconf()
with an argument of _PC_PATH_MAX.
This function resolves both absolute and relative paths and
returns the absolute pathname corresponding to pathname. All but the last
component of pathname must exist when realpath() is called.
A pointer to resolved_name, or NULL if an error
occurs, in which case resolved_name contains the pathname
that caused the problem.
The realpath() function may fail and set the external variable
errno
to any of the errors specified for the library functions
chdir(),
close(),
fchdir(),
lstat(),
open(),
readlink()
and
getcwd().
POSIX 1003.1 XSI
Safety: | |
Cancellation point |
Yes |
Interrupt handler |
No |
Signal handler |
Yes |
Thread |
Yes |
getcwd()
Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 145
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/neutrino/lib_ref/r/realpath.html on line 145