1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-01-24 16:52:24 +00:00

Remove a redundant failure check after an snew.

I spotted this at some point during this week's BinarySink
refactoring, but only just remembered to come back and fix it. snew
aborts the whole program rather than return NULL, so there's no need
to check its return value against NULL.
This commit is contained in:
Simon Tatham 2018-05-26 06:10:06 +01:00
parent b95a6dece6
commit 2bfbf15c65

View File

@ -725,10 +725,6 @@ struct ssh2_userkey *openssh_pem_read(const Filename *filename,
/* Construct the key */ /* Construct the key */
retkey = snew(struct ssh2_userkey); retkey = snew(struct ssh2_userkey);
if (!retkey) {
errmsg = "out of memory";
goto error;
}
retkey->alg = alg; retkey->alg = alg;
put_stringz(blob, alg->name); put_stringz(blob, alg->name);