Mail Archives: djgpp-workers/1999/02/22/19:26:45
Tommorrow already? Well, here's my first cut at chroot.txh:
*** chroot.txh Mon Feb 22 18:05:28 1999
--- src/libc/posix/unistd/chroot.txh Mon Feb 22 19:16:30 1999
***************
*** 0 ****
--- 1,34 ----
+ @node chroot, file system
+ @subheading Syntax
+
+ @example
+ #include <unistd.h>
+
+ int chroot(const char *new_root_directory);
+ @end example
+
+ @subheading Description
+
+ This function changes the root directory for absolute paths
+ to @var{new_root_directory}. If @var{new_root_directory} is NULL
+ or points to an empty string, then the root directory will be
+ will be the actual root directory of the current working drive.
+
+ @subheading Return Value
+
+ Always returns 0 to indicate the root directory
+ was successfully changed.
+
+ @subheading Portability
+
+ @portability !ansi, posix
+
+ @subheading Example
+
+ @example
+ int status;
+ chroot("c:/djgpp");
+ status = access("/bin/gcc.exe");
+ printf ("status = %i\n", status);
+ @end example
+
---
Mark Elbrecht
snowball3 AT usa DOT net http://members.xoom.com/snowball3/
- Raw text -