mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-21 01:01:02 +00:00
Add a linkedlist macro that maintains a sorted list
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@111036 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -878,7 +878,7 @@ static void config_cache_attribute(const char *configfile, enum config_cache_att
|
||||
cfmtime->who_asked = cfmtime->filename + strlen(configfile) + 1;
|
||||
strcpy(cfmtime->who_asked, who_asked);
|
||||
/* Note that the file mtime is initialized to 0, i.e. 1970 */
|
||||
AST_LIST_INSERT_TAIL(&cfmtime_head, cfmtime, list);
|
||||
AST_LIST_INSERT_SORTALPHA(&cfmtime_head, cfmtime, list, filename);
|
||||
}
|
||||
|
||||
if (!stat(configfile, &statbuf))
|
||||
@@ -1211,7 +1211,7 @@ static struct ast_config *config_text_file_load(const char *database, const char
|
||||
cfmtime->who_asked = cfmtime->filename + strlen(fn) + 1;
|
||||
strcpy(cfmtime->who_asked, who_asked);
|
||||
/* Note that the file mtime is initialized to 0, i.e. 1970 */
|
||||
AST_LIST_INSERT_TAIL(&cfmtime_head, cfmtime, list);
|
||||
AST_LIST_INSERT_SORTALPHA(&cfmtime_head, cfmtime, list, filename);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user