aboutsummaryrefslogtreecommitdiffstats
path: root/set.h
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2006-08-25 00:06:52 +0200
committerWilmer van der Gaast <wilmer@gaast.net>2006-08-25 00:06:52 +0200
commit0383943c38ee308805798974bfccbd3327369c6a (patch)
tree73e72fe7177ada30828780ac7b6e7c3fc6a61f94 /set.h
parent9829ae028dc1f0d8ab60cb18293234f2d4cc19b8 (diff)
Added message on successful creation of accounts and fixed "set password"
command.
Diffstat (limited to 'set.h')
-rw-r--r--set.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/set.h b/set.h
index 14043c2f..37d2430f 100644
--- a/set.h
+++ b/set.h
@@ -33,6 +33,8 @@
every setting, which can check a new value and block it by returning
NULL, or replace it by returning a new value. See struct set.eval. */
+typedef char *(*set_eval) ( struct set *set, char *value );
+
typedef struct set
{
void *data; /* Here you can save a pointer to the
@@ -51,12 +53,12 @@ typedef struct set
/* Eval: Returns NULL if the value is incorrect or exactly the
passed value variable. When returning a corrected value,
set_setstr() should be able to free() the returned string! */
- char *(*eval) ( struct set *set, char *value );
+ set_eval eval;
struct set *next;
} set_t;
/* Should be pretty clear. */
-set_t *set_add( set_t **head, char *key, char *def, void *eval, void *data );
+set_t *set_add( set_t **head, char *key, char *def, set_eval eval, void *data );
/* Returns the raw set_t. Might be useful sometimes. */
set_t *set_find( set_t **head, char *key );