| 377 { |
377 { |
| 378 int port = default_port; |
378 int port = default_port; |
| 379 char *d; |
379 char *d; |
| 380 |
380 |
| 381 d = g_strrstr(host, ":"); |
381 d = g_strrstr(host, ":"); |
| 382 if (d) |
382 if (d) { |
| 383 *d = '\0'; |
383 *d = '\0'; |
| 384 d++; |
384 |
| 385 if (*d) |
385 d++; |
| 386 sscanf(d, "%d", &port); |
386 if (*d) |
| |
387 sscanf(d, "%d", &port); |
| |
388 |
| |
389 if (port == 0) |
| |
390 port = default_port; |
| |
391 } |
| 387 |
392 |
| 388 purple_proxy_info_set_host(info, host); |
393 purple_proxy_info_set_host(info, host); |
| 389 purple_proxy_info_set_port(info, port); |
394 purple_proxy_info_set_port(info, port); |
| 390 } |
395 } |
| 391 |
396 |