Merge branch '2833_url_port_in_history'

* 2833_url_port_in_history:
  Ticket #2833: url with port was stored wrong in history.
This commit is contained in:
Andrew Borodin 2012-06-20 15:57:11 +04:00
commit c654147913
1 changed files with 5 additions and 0 deletions

View File

@ -233,6 +233,11 @@ input_history_strip_password (char *url)
else
colon = strchr (url, ':');
/* if 'colon' before 'at', 'colon' delimits user and password: user:password@host */
/* if 'colon' after 'at', 'colon' delimits host and port: user@host:port */
if (colon != NULL && colon > at)
colon = NULL;
if (colon == NULL)
return g_strdup (url);
*colon = '\0';