X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=psftp.c;h=3fdfa45ab224eee6449d497e59642679a82b60c9;hb=b4e7ec8b12e19895ea509653090c43a5a1c52ed1;hp=f8d1f79923f4679478f0560059d0ea578040c435;hpb=f49c8c5a070f9757940f79a8ab583dc7e820eda8;p=PuTTY.git diff --git a/psftp.c b/psftp.c index f8d1f799..3fdfa45a 100644 --- a/psftp.c +++ b/psftp.c @@ -34,6 +34,7 @@ static int do_sftp_init(void); char *pwd, *homedir; static Backend *back; static void *backhandle; +static Config cfg; /* ---------------------------------------------------------------------- * Higher-level helper functions used in commands. @@ -1527,7 +1528,7 @@ static unsigned char *outptr; /* where to put the data */ static unsigned outlen; /* how much data required */ static unsigned char *pending = NULL; /* any spare data */ static unsigned pendlen = 0, pendsize = 0; /* length and phys. size of buffer */ -int from_backend(void *frontend, int is_stderr, char *data, int datalen) +int from_backend(void *frontend, int is_stderr, const char *data, int datalen) { unsigned char *p = (unsigned char *) data; unsigned len = (unsigned) datalen; @@ -1833,8 +1834,9 @@ static int psftp_connect(char *userhost, char *user, int portnumber) fprintf(stderr, "ssh_init: %s\n", err); return 1; } - logctx = log_init(NULL); + logctx = log_init(NULL, &cfg); back->provide_logctx(backhandle, logctx); + console_provide_logctx(logctx); ssh_sftp_init(); if (verbose && realhost != NULL) printf("Connected to %s\n", realhost);