diff options
author | unknown <reggie@bob.(none)> | 2005-01-17 14:08:36 -0600 |
---|---|---|
committer | unknown <reggie@bob.(none)> | 2005-01-17 14:08:36 -0600 |
commit | 5847d10712fac59beae024c76b8b6ef13d0df558 (patch) | |
tree | 0f919d7354ffd61b6beeeeb265b86ddb9d3cddf6 /client | |
parent | 0b076d2c1fa0df44033ca43a5f384eefaba71c9b (diff) | |
parent | f6f90e7dc1ae497ac25941fc6b709f18a5d46c46 (diff) | |
download | mariadb-git-5847d10712fac59beae024c76b8b6ef13d0df558.tar.gz |
Merge rburnett@bk-internal.mysql.com:/home/bk/mysql-4.1
into bob.(none):/home/reggie/bk/mysql-4.1
BitKeeper/etc/logging_ok:
auto-union
client/mysql.cc:
Auto merged
Diffstat (limited to 'client')
-rw-r--r-- | client/mysql.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/client/mysql.cc b/client/mysql.cc index b9251361a01..480a0deb347 100644 --- a/client/mysql.cc +++ b/client/mysql.cc @@ -3232,13 +3232,20 @@ static const char* construct_prompt() break; } case 'p': + { #ifndef EMBEDDED_LIBRARY if (!connected) { processed_prompt.append("not_connected"); break; } - if (strstr(mysql_get_host_info(&mysql),"TCP/IP") || + + const char *host_info = mysql_get_host_info(&mysql); + if (strstr(host_info, "memory")) + { + processed_prompt.append( mysql.host ); + } + else if (strstr(host_info,"TCP/IP") || !mysql.unix_socket) add_int_to_prompt(mysql.port); else @@ -3247,6 +3254,7 @@ static const char* construct_prompt() processed_prompt.append(pos ? pos+1 : mysql.unix_socket); } #endif + } break; case 'U': if (!full_username) |