]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
Merge branch 'master' into smgmaster
authorMoises Silva <moy@sangoma.com>
Sat, 17 Dec 2011 22:25:36 +0000 (17:25 -0500)
committerMoises Silva <moy@sangoma.com>
Sat, 17 Dec 2011 22:25:36 +0000 (17:25 -0500)
Conflicts:
build/modules.conf.in
libs/esl/fs_cli.c

1  2 
libs/esl/fs_cli.c
src/mod/applications/mod_commands/mod_commands.c
src/mod/endpoints/mod_sofia/mod_sofia.c
src/mod/endpoints/mod_sofia/mod_sofia.h
src/mod/loggers/mod_logfile/mod_logfile.c
src/switch.c
src/switch_apr.c
src/switch_core.c
src/switch_loadable_module.c

index 0f432f464f44be413f3740c9b486140acaa932be,108b42cf6e99a2c2c2af527052a797dc04b3f22b..53d1bdfce4f69d6828c3e0875053647e84b4cccd
@@@ -1103,15 -1115,16 +1105,16 @@@ int main(int argc, char *argv[]
        char cmd_str[1024] = "";
        cli_profile_t *profile = NULL;
  #ifndef WIN32
 -      char hfile[512] = "/tmp/fs_cli_history";
 -      char cfile[512] = "/etc/fs_cli.conf";
 -      char dft_cfile[512] = "/etc/fs_cli.conf";
 +      char hfile[512] = "/etc/nbess7_cli_history";
 +      char cfile[512] = "/etc/nbess7_cli.conf";
 +      char dft_cfile[512] = "/etc/nbess7_cli.conf";
  #else
 -      char hfile[512] = "fs_cli_history";
 -      char cfile[512] = "fs_cli.conf";
 -      char dft_cfile[512] = "fs_cli.conf";
 +      char hfile[512] = "nbess7_cli_history";
 +      char cfile[512] = "nbess7_cli.conf";
 +      char dft_cfile[512] = "nbess7_cli.conf";
  #endif
        char *home = getenv("HOME");
+       char *term = getenv("TERM");
        /* Vars for optargs */
        int opt;
        static struct option options[] = {
        esl_set_string(input_text_color, profile->input_text_color);
        esl_set_string(output_text_color, profile->output_text_color);
        if (argv_host) {
 -              if (argv_port && profile->port != 8021) {
 -                      snprintf(bare_prompt_str, sizeof(bare_prompt_str), "freeswitch@%s:%u@%s> ", profile->host, profile->port, profile->name);
 +              if (argv_port && profile->port != 8821) {
 +                      snprintf(prompt_str, sizeof(prompt_str), PROMPT_PREFIX "@%s:%u@%s> ", profile->host, profile->port, profile->name);
                } else {
 -                      snprintf(bare_prompt_str, sizeof(bare_prompt_str), "freeswitch@%s@%s> ", profile->host, profile->name);
 +                      snprintf(prompt_str, sizeof(prompt_str), PROMPT_PREFIX "@%s@%s> ", profile->host, profile->name);
                }
        } else {
 -              snprintf(bare_prompt_str, sizeof(bare_prompt_str), "freeswitch@%s> ", profile->name);
 +              snprintf(prompt_str, sizeof(prompt_str), PROMPT_PREFIX "@%s> ", profile->name);
        }
        bare_prompt_str_len = (int)strlen(bare_prompt_str);
- #ifdef WIN32
-       snprintf(prompt_str, sizeof(prompt_str), "%s", bare_prompt_str); /* Not supporting this for now */
- #else
-       snprintf(prompt_str, sizeof(prompt_str), "%s%s%s", prompt_color, bare_prompt_str, input_text_color);
- #endif
+       if (feature_level) {
+               snprintf(prompt_str, sizeof(prompt_str), "%s%s%s", prompt_color, bare_prompt_str, input_text_color);
+       } else {
+               snprintf(prompt_str, sizeof(prompt_str), "%s", bare_prompt_str);
+       }
   connect:
        connected = 0;
        while (--loops > 0) {
diff --cc src/switch.c
Simple merge
Simple merge
Simple merge
Simple merge