diff options
author | Nick Mathewson <nickm@torproject.org> | 2011-05-13 14:55:40 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2011-05-15 20:20:29 -0400 |
commit | b147c01295deb8c09807fda3b5e4945edcfaf81a (patch) | |
tree | 105f79fccb25781e12b6ba39218c131a1e3e101d /src/common/util.h | |
parent | 4198261291c8edbd5ba1617b7bfe3563e51edbe7 (diff) | |
download | tor-b147c01295deb8c09807fda3b5e4945edcfaf81a.tar.gz tor-b147c01295deb8c09807fda3b5e4945edcfaf81a.zip |
Make check_private_dir accept g+rx dirs if told to do so.
Diffstat (limited to 'src/common/util.h')
-rw-r--r-- | src/common/util.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/common/util.h b/src/common/util.h index 961b5875ad..f75953226b 100644 --- a/src/common/util.h +++ b/src/common/util.h @@ -286,7 +286,11 @@ file_status_t file_status(const char *filename); /** Possible behaviors for check_private_dir() on encountering a nonexistent * directory; see that function's documentation for details. */ -typedef enum { CPD_NONE, CPD_CREATE, CPD_CHECK } cpd_check_t; +typedef unsigned int cpd_check_t; +#define CPD_NONE 0 +#define CPD_CREATE 1 +#define CPD_CHECK 2 +#define CPD_GROUP_OK 4 int check_private_dir(const char *dirname, cpd_check_t check); #define OPEN_FLAGS_REPLACE (O_WRONLY|O_CREAT|O_TRUNC) #define OPEN_FLAGS_APPEND (O_WRONLY|O_CREAT|O_APPEND) |