|
|
|
@ -3422,16 +3422,21 @@ static int load_config(void)
|
|
|
|
msg_format = ast_strdupa(var->value);
|
|
|
|
msg_format = ast_strdupa(var->value);
|
|
|
|
if (msg_format != NULL) {
|
|
|
|
if (msg_format != NULL) {
|
|
|
|
timezone = strsep(&msg_format, "|");
|
|
|
|
timezone = strsep(&msg_format, "|");
|
|
|
|
strncpy(z->name, var->name, sizeof(z->name) - 1);
|
|
|
|
if (msg_format) {
|
|
|
|
strncpy(z->timezone, timezone, sizeof(z->timezone) - 1);
|
|
|
|
strncpy(z->name, var->name, sizeof(z->name) - 1);
|
|
|
|
strncpy(z->msg_format, msg_format, sizeof(z->msg_format) - 1);
|
|
|
|
strncpy(z->timezone, timezone, sizeof(z->timezone) - 1);
|
|
|
|
z->next = NULL;
|
|
|
|
strncpy(z->msg_format, msg_format, sizeof(z->msg_format) - 1);
|
|
|
|
if (zones) {
|
|
|
|
z->next = NULL;
|
|
|
|
zonesl->next = z;
|
|
|
|
if (zones) {
|
|
|
|
zonesl = z;
|
|
|
|
zonesl->next = z;
|
|
|
|
|
|
|
|
zonesl = z;
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
zones = z;
|
|
|
|
|
|
|
|
zonesl = z;
|
|
|
|
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
zones = z;
|
|
|
|
ast_log(LOG_WARNING, "Invalid tonezone definition at line %d\n", var->lineno);
|
|
|
|
zonesl = z;
|
|
|
|
free(z);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
ast_log(LOG_WARNING, "Out of memory while reading voicemail config\n");
|
|
|
|
ast_log(LOG_WARNING, "Out of memory while reading voicemail config\n");
|
|
|
|
|