mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-10 01:48:00 +00:00
Remove a fixed-size buffer in cmdgen.c.
This patch solves the same problem as in previous commit: the fixed-size buffer may have less size than data placed into it.
This commit is contained in:
parent
5eb4efce01
commit
ed70e6014c
5
cmdgen.c
5
cmdgen.c
@ -1281,14 +1281,15 @@ int main(int argc, char **argv)
|
||||
setup_passphrases(NULL);
|
||||
test(0, "puttygen", "-L", filename, "-o", pubfilename, NULL);
|
||||
{
|
||||
char cmdbuf[256];
|
||||
char *cmdbuf;
|
||||
fp = NULL;
|
||||
sprintf(cmdbuf, "ssh-keygen -l -f '%s' > '%s'",
|
||||
cmdbuf = dupprintf("ssh-keygen -l -f '%s' > '%s'",
|
||||
pubfilename, tmpfilename1);
|
||||
if (system(cmdbuf) ||
|
||||
(fp = get_fp(tmpfilename1)) == NULL) {
|
||||
printf("UNABLE to test fingerprint matching against OpenSSH");
|
||||
}
|
||||
sfree(cmdbuf);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user