Changed admin list configuration behavior
This commit is contained in:
parent
399eb45986
commit
5812a15092
@ -202,14 +202,15 @@ parse_admin_list(char const * admin_list_path)
|
||||
char * line = NULL;
|
||||
size_t nread = 0;
|
||||
|
||||
admins = calloc(ADMIN_LIST_INIT_SIZE, sizeof(char *));
|
||||
|
||||
stream = fopen(admin_list_path, "r");
|
||||
if (stream == NULL)
|
||||
{
|
||||
PERROR(1);
|
||||
/* Pretty valid case I guess? No admin file = no admins, maybe all configuration is performed locally */
|
||||
return 0;
|
||||
}
|
||||
|
||||
admins = calloc(ADMIN_LIST_INIT_SIZE, sizeof(char *));
|
||||
|
||||
while (getline(&line, &nread, stream) > 0)
|
||||
{
|
||||
if (++lines_read > current_array_size)
|
||||
|
Reference in New Issue
Block a user