]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-11184: [core] fix build errors
authorMike Jerris <mike@signalwire.com>
Tue, 12 Feb 2019 16:52:12 +0000 (11:52 -0500)
committerMike Jerris <mike@signalwire.com>
Tue, 12 Feb 2019 16:52:12 +0000 (11:52 -0500)
src/switch_xml.c

index 95c01bc10dd100adaf63707a384e97571d7f2de7..58ec1fb411cb7b1ff13d42a9a861635147d3a1b5 100644 (file)
@@ -3274,11 +3274,12 @@ SWITCH_DECLARE(switch_status_t) switch_xml_locate_language(switch_xml_t *root, s
        switch_status_t status;
 
        if ((status = switch_xml_locate_language_ex(root, node, params, language, phrases, macros, str_language)) != SWITCH_STATUS_SUCCESS) {
-               const char *str_language_dup = strdup(str_language);
+               char *str_language_dup = strdup(str_language);
                char *secondary;
-               if ((secondary=strchr(str_language_dup, '-')) != NULL) {
+               if ((secondary = strchr(str_language_dup, '-'))) {
                        *secondary++ = '\0';
-                       switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "language %s not found. trying %s by removing %s\n", str_language, str_language_dup, secondary);
+                       switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING,
+                                                         "language %s not found. trying %s by removing %s\n", str_language, str_language_dup, secondary);
                        switch_event_add_header_string(params, SWITCH_STACK_BOTTOM, "lang", str_language_dup);
                        status = switch_xml_locate_language_ex(root, node, params, language, phrases, macros, str_language_dup);
                }