diff options
author | Robert James Kaes <rjkaes@users.sourceforge.net> | 2003-07-31 23:38:28 +0000 |
---|---|---|
committer | Robert James Kaes <rjkaes@users.sourceforge.net> | 2003-07-31 23:38:28 +0000 |
commit | 6aaa863432967b99d0e2c87116b4ec844b90436f (patch) | |
tree | 40d8a50800514332aab7e469c351e4491cab6dfe /src/acl.c | |
parent | ab02f47a297693752e1d68d5eaf914c77cfb652c (diff) |
Added appropriate casts from (void*) so that the code will compile
cleanly with a C++ compiler. (Tested using GCC 3.3)
Diffstat (limited to 'src/acl.c')
-rw-r--r-- | src/acl.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -1,4 +1,4 @@ -/* $Id: acl.c,v 1.16 2002-06-05 16:59:21 rjkaes Exp $ +/* $Id: acl.c,v 1.17 2003-07-31 23:38:28 rjkaes Exp $ * * This system handles Access Control for use of this daemon. A list of * domains, or IP addresses (including IP blocks) are stored in a list @@ -24,9 +24,11 @@ #include "log.h" #include "sock.h" +enum acl_type { ACL_STRING, ACL_NUMERIC }; + struct acl_s { acl_access_t acl_access; - enum { ACL_STRING, ACL_NUMERIC } type; + enum acl_type type; char *location; int netmask; struct acl_s *next; @@ -85,7 +87,7 @@ insert_acl(char *location, acl_access_t access_type) rev_acl_ptr = &acl_ptr->next; acl_ptr = acl_ptr->next; } - new_acl_ptr = safemalloc(sizeof(struct acl_s)); + new_acl_ptr = (struct acl_s*)safemalloc(sizeof(struct acl_s)); if (!new_acl_ptr) { return -1; } |