diff options
| author | Franklin Wei <git@fwei.tk> | 2016-01-08 22:27:43 -0500 |
|---|---|---|
| committer | Franklin Wei <git@fwei.tk> | 2016-01-08 22:27:43 -0500 |
| commit | 50134c46dc337c35b8ecf78b3c5b4308cf8fb791 (patch) | |
| tree | 89d73bca1951129ec7e15b642e2fa6c85567f872 /src/userdb.h | |
| parent | 2819d11ceeb1ac739ed5f17ccb0abab63f494299 (diff) | |
| download | netcosm-50134c46dc337c35b8ecf78b3c5b4308cf8fb791.zip netcosm-50134c46dc337c35b8ecf78b3c5b4308cf8fb791.tar.gz netcosm-50134c46dc337c35b8ecf78b3c5b4308cf8fb791.tar.bz2 netcosm-50134c46dc337c35b8ecf78b3c5b4308cf8fb791.tar.xz | |
some stuff
Diffstat (limited to 'src/userdb.h')
| -rw-r--r-- | src/userdb.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/userdb.h b/src/userdb.h index 89e2566..ac169b2 100644 --- a/src/userdb.h +++ b/src/userdb.h @@ -1,4 +1,5 @@ #include "netcosm.h" +#include "auth.h" /* * on-disk database for storing user data @@ -7,7 +8,7 @@ */ struct userdata_t { - char *username; + char username[MAX_NAME_LEN + 1]; char salt[SALT_LEN + 1]; @@ -23,7 +24,7 @@ void userdb_init(const char *dbfile); /* looks up a username in the DB, returns NULL upon failure */ struct userdata_t *userdb_lookup(const char *username); -void userdb_remove(const char *username); +bool userdb_remove(const char *username); /* is it empty? */ size_t userdb_size(void); |