From 7afdd17fcae600bab54815d6458120220512076d Mon Sep 17 00:00:00 2001 From: "Reece H. Dunn" Date: Tue, 29 Dec 2015 17:14:41 +0000 Subject: [PATCH] Merge identical code branches in speak-ng. --- src/speak-ng.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/src/speak-ng.c b/src/speak-ng.c index f9dbd930..df126cf3 100644 --- a/src/speak-ng.c +++ b/src/speak-ng.c @@ -676,22 +676,15 @@ int main(int argc, char **argv) } if (flag_compile) { -#ifdef PLATFORM_DOS - char path_dsource[sizeof(path_home)+20]; - strcpy(path_dsource, path_home); - path_dsource[strlen(path_home)-11] = 0; // remove "espeak-data" from the end - strcat(path_dsource, "dictsource\\"); - espeak_ng_STATUS status = espeak_ng_CompileDictionary(path_dsource, dictionary_name, NULL, flag_compile & 0x1); -#else -#ifdef PLATFORM_WINDOWS +#if defined(PLATFORM_DOS) || defined(PLATFORM_WINDOWS) char path_dsource[sizeof(path_home)+20]; strcpy(path_dsource, path_home); path_dsource[strlen(path_home)-11] = 0; // remove "espeak-data" from the end strcat(path_dsource, "dictsource\\"); + espeak_ng_STATUS status = espeak_ng_CompileDictionary(path_dsource, dictionary_name, NULL, flag_compile & 0x1); #else espeak_ng_STATUS status = espeak_ng_CompileDictionary(NULL, dictionary_name, NULL, flag_compile & 0x1); -#endif #endif return (status == ENS_OK) ? EXIT_SUCCESS : EXIT_FAILURE; }