projects
/
u
/
mdw
/
putty
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Support for non-ISO-8859-1 X keysyms. So in particular, pterm in a
[u/mdw/putty]
/
plink.c
diff --git
a/plink.c
b/plink.c
index
7ada2d4
..
d61bbeb
100644
(file)
--- a/
plink.c
+++ b/
plink.c
@@
-69,6
+69,7
@@
WSAEVENT netevent;
static Backend *back;
static void *backhandle;
static Backend *back;
static void *backhandle;
+static Config cfg;
int term_ldisc(Terminal *term, int mode)
{
int term_ldisc(Terminal *term, int mode)
{
@@
-165,7
+166,8
@@
void try_output(int is_stderr)
}
}
}
}
-int from_backend(void *frontend_handle, int is_stderr, char *data, int len)
+int from_backend(void *frontend_handle, int is_stderr,
+ const char *data, int len)
{
int osize, esize;
{
int osize, esize;
@@
-205,6
+207,7
@@
static void usage(void)
printf(" -batch disable all interactive prompts\n");
printf("The following options only apply to SSH connections:\n");
printf(" -pw passw login with specified password\n");
printf(" -batch disable all interactive prompts\n");
printf("The following options only apply to SSH connections:\n");
printf(" -pw passw login with specified password\n");
+ printf(" -D listen-port Dynamic SOCKS-based port forwarding\n");
printf(" -L listen-port:host:port Forward local port to "
"remote address\n");
printf(" -R listen-port:host:port Forward remote port to"
printf(" -L listen-port:host:port Forward local port to "
"remote address\n");
printf(" -R listen-port:host:port Forward remote port to"
@@
-408,13
+411,13
@@
int main(int argc, char **argv)
while (*p) {
if (cmdlen >= cmdsize) {
cmdsize = cmdlen + 512;
while (*p) {
if (cmdlen >= cmdsize) {
cmdsize = cmdlen + 512;
- command = sre
alloc(command, cmdsize
);
+ command = sre
size(command, cmdsize, char
);
}
command[cmdlen++]=*p++;
}
if (cmdlen >= cmdsize) {
cmdsize = cmdlen + 512;
}
command[cmdlen++]=*p++;
}
if (cmdlen >= cmdsize) {
cmdsize = cmdlen + 512;
- command = sre
alloc(command, cmdsize
);
+ command = sre
size(command, cmdsize, char
);
}
command[cmdlen++]=' '; /* always add trailing space */
if (--argc) p = *++argv;
}
command[cmdlen++]=' '; /* always add trailing space */
if (--argc) p = *++argv;
@@
-539,14
+542,15
@@
int main(int argc, char **argv)
int nodelay = cfg.tcp_nodelay &&
(GetFileType(GetStdHandle(STD_INPUT_HANDLE)) == FILE_TYPE_CHAR);
int nodelay = cfg.tcp_nodelay &&
(GetFileType(GetStdHandle(STD_INPUT_HANDLE)) == FILE_TYPE_CHAR);
- error = back->init(NULL, &backhandle, cfg.host, cfg.port,
+ error = back->init(NULL, &backhandle,
&cfg,
cfg.host, cfg.port,
&realhost, nodelay);
if (error) {
fprintf(stderr, "Unable to open connection:\n%s", error);
return 1;
}
&realhost, nodelay);
if (error) {
fprintf(stderr, "Unable to open connection:\n%s", error);
return 1;
}
- logctx = log_init(NULL);
+ logctx = log_init(NULL
, &cfg
);
back->provide_logctx(backhandle, logctx);
back->provide_logctx(backhandle, logctx);
+ console_provide_logctx(logctx);
sfree(realhost);
}
connopen = 1;
sfree(realhost);
}
connopen = 1;
@@
-648,7
+652,7
@@
int main(int argc, char **argv)
/* Expand the buffer if necessary. */
if (i > sksize) {
sksize = i + 16;
/* Expand the buffer if necessary. */
if (i > sksize) {
sksize = i + 16;
- sklist = sre
alloc(sklist, sksize * sizeof(*sklist)
);
+ sklist = sre
size(sklist, sksize, SOCKET
);
}
/* Retrieve the sockets into sklist. */
}
/* Retrieve the sockets into sklist. */