mirror of
https://github.com/servalproject/serval-dna.git
synced 2024-12-24 07:16:43 +00:00
Fix segfaults
This commit is contained in:
parent
c79c5d8968
commit
f6ed8f1562
@ -103,6 +103,7 @@ static void directory_update(struct sched_ent *alarm){
|
||||
if (subscriber_is_reachable(directory_service) != REACHABLE_NONE){
|
||||
directory_send_keyring(directory_service);
|
||||
|
||||
unschedule(alarm);
|
||||
alarm->alarm = gettime_ms() + DIRECTORY_UPDATE_INTERVAL;
|
||||
alarm->deadline = alarm->alarm + 10000;
|
||||
schedule(alarm);
|
||||
@ -112,7 +113,6 @@ static void directory_update(struct sched_ent *alarm){
|
||||
}
|
||||
|
||||
int directory_service_init(){
|
||||
unschedule(&directory_alarm);
|
||||
directory_update(&directory_alarm);
|
||||
return 0;
|
||||
}
|
||||
|
@ -14,7 +14,7 @@ struct item{
|
||||
time_ms_t expires;
|
||||
};
|
||||
|
||||
struct item *root;
|
||||
struct item *root=NULL;
|
||||
|
||||
static struct item *create_item(const char *key){
|
||||
struct item *ret=calloc(1,sizeof(struct item));
|
||||
|
Loading…
Reference in New Issue
Block a user