Browse files

Fix several bugs that stopped %proxyport from doing anything useful.

git-svn-id: svn://svn.tartarus.org/sgt/putty@7133 cda61777-01e9-0310-a592-d414129be87e
  • Loading branch information...
1 parent 600f649 commit 3d291a547e2ad9fa88c13e9cb6eb1f38976471bc jacob committed Jan 21, 2007
Showing with 3 additions and 3 deletions.
  1. +3 −3 proxy.c
View
6 proxy.c
@@ -1369,19 +1369,19 @@ char *format_telnet_command(SockAddr addr, int port, const Config *cfg)
eo += 4;
}
else if (strnicmp(cfg->proxy_telnet_command + eo,
- "proxyhost", 4) == 0) {
+ "proxyhost", 9) == 0) {
int phlen = strlen(cfg->proxy_host);
ENSURE(phlen);
memcpy(ret+retlen, cfg->proxy_host, phlen);
retlen += phlen;
eo += 9;
}
else if (strnicmp(cfg->proxy_telnet_command + eo,
- "proxyport", 4) == 0) {
+ "proxyport", 9) == 0) {
char pport[50];
int pplen;
sprintf(pport, "%d", cfg->proxy_port);
- pplen = strlen(cfg->proxy_host);
+ pplen = strlen(pport);
ENSURE(pplen);
memcpy(ret+retlen, pport, pplen);
retlen += pplen;

0 comments on commit 3d291a5

Please sign in to comment.