| free((*context)->path); | free((*context)->path); | ||||
| } else { | } else { | ||||
| *context = malloc(sizeof(espeak_ng_ERROR_CONTEXT_)); | *context = malloc(sizeof(espeak_ng_ERROR_CONTEXT_)); | ||||
| if (!*context) | |||||
| return ENOMEM; | |||||
| } | } | ||||
| (*context)->type = ERROR_CONTEXT_FILE; | (*context)->type = ERROR_CONTEXT_FILE; | ||||
| (*context)->path = strdup(filename); | (*context)->path = strdup(filename); | ||||
| free((*context)->path); | free((*context)->path); | ||||
| } else { | } else { | ||||
| *context = malloc(sizeof(espeak_ng_ERROR_CONTEXT_)); | *context = malloc(sizeof(espeak_ng_ERROR_CONTEXT_)); | ||||
| if (!*context) | |||||
| return ENOMEM; | |||||
| } | } | ||||
| (*context)->type = ERROR_CONTEXT_VERSION; | (*context)->type = ERROR_CONTEXT_VERSION; | ||||
| (*context)->path = strdup(path_home); | (*context)->path = strdup(path_home); |