mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-11 14:19:59 -04:00
434. [func] New function isc_file_isabsolute().
This commit is contained in:
parent
ec393c0384
commit
7ec4367f3d
3 changed files with 15 additions and 3 deletions
2
CHANGES
2
CHANGES
|
|
@ -1,4 +1,6 @@
|
|||
|
||||
434. [func] New function isc_file_isabsolute().
|
||||
|
||||
433. [func] isc_base64_decodestring() now accepts newlines
|
||||
within the base64 data. This makes it possible
|
||||
to break up the key data in a "trusted-keys"
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: file.h,v 1.9 2000/08/01 01:30:10 tale Exp $ */
|
||||
/* $Id: file.h,v 1.10 2000/09/08 18:37:25 gson Exp $ */
|
||||
|
||||
#ifndef ISC_FILE_H
|
||||
#define ISC_FILE_H 1
|
||||
|
|
@ -159,13 +159,18 @@ isc_file_remove(const char *filename);
|
|||
* Remove the file named by 'filename'.
|
||||
*/
|
||||
|
||||
isc_boolean_t
|
||||
isc_file_isabsolute(const char *filename);
|
||||
/*
|
||||
* Return ISC_TRUE iff the given file name is absolute.
|
||||
*/
|
||||
|
||||
/*
|
||||
* XXX We should also have a isc_file_writeeopen() function
|
||||
* for safely open a file in a publicly writable directory
|
||||
* (see write_open() in BIND 8's ns_config.c).
|
||||
*/
|
||||
|
||||
|
||||
ISC_LANG_ENDDECLS
|
||||
|
||||
#endif /* ISC_FILE_H */
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: file.c,v 1.20 2000/08/01 01:31:16 tale Exp $ */
|
||||
/* $Id: file.c,v 1.21 2000/09/08 18:37:26 gson Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
|
|
@ -180,3 +180,8 @@ isc_file_remove(const char *filename) {
|
|||
else
|
||||
return (isc__errno2result(errno));
|
||||
}
|
||||
|
||||
isc_boolean_t
|
||||
isc_file_isabsolute(const char *filename) {
|
||||
return (ISC_TF(filename[0] == '/'));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue