2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-30 22:15:20 +00:00

isc_dir_chroot()

This commit is contained in:
Mark Andrews
2001-01-29 03:17:45 +00:00
parent 5535230782
commit fd50497bbe
2 changed files with 16 additions and 2 deletions

View File

@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dir.c,v 1.15 2001/01/09 21:58:12 bwelling Exp $ */
/* $Id: dir.c,v 1.16 2001/01/29 03:17:44 marka Exp $ */
/* Principal Authors: DCL */
@@ -144,6 +144,17 @@ isc_dir_chdir(const char *dirname) {
return (ISC_R_SUCCESS);
}
isc_result_t
isc_dir_chroot(const char *dirname) {
REQUIRE(dirname != NULL);
if (chroot(dirname) < 0)
return (isc__errno2result(errno));
return (ISC_R_SUCCESS);
}
isc_result_t
isc_dir_createunique(char *templet) {
isc_result_t result;