]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Fix warning about uninitialized variable.
authorTim Kosse <tim.kosse@filezilla-project.org>
Tue, 11 Aug 2015 08:44:00 +0000 (10:44 +0200)
committerSimon Tatham <anakin@pobox.com>
Sat, 15 Aug 2015 12:54:39 +0000 (13:54 +0100)
Some MinGW versions do not know that assert(0) never returns. This
change also handles the case of building with NDEBUG.

import.c

index 51b236a0517b29e92c0cb8c901ea18ab0386cc34..508ef782a03b2f62541ac1cb51213d7a7baa4185 100644 (file)
--- a/import.c
+++ b/import.c
@@ -886,6 +886,8 @@ struct ssh2_userkey *openssh_pem_read(const Filename *filename,
 
     } else {
         assert(0 && "Bad key type from load_openssh_pem_key");
+       errmsg = "Bad key type from load_openssh_pem_key";
+       goto error;
     }
 
     /*