Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/crypto/external/bsd/openssh/dist Add a "gcc is stupid" comme...



details:   https://anonhg.NetBSD.org/src/rev/7be2a5a4877b
branches:  trunk
changeset: 365171:7be2a5a4877b
user:      kre <kre%NetBSD.org@localhost>
date:      Fri Aug 03 12:49:41 2018 +0000

description:
Add a "gcc is stupid" comment to the previous change, as even
the most cursory analysis shows that the var ("eg") is not (cannot
be) used unitialialised, just gcc is too dumb to work it out.

In this case, the code could be rewritten easily enough to
appease even gcc, but that would cause unnecessary code churn,
and some minor duplication, so just put up with the nonsense init...

diffstat:

 crypto/external/bsd/openssh/dist/sshkey.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r a0a64cdc6497 -r 7be2a5a4877b crypto/external/bsd/openssh/dist/sshkey.c
--- a/crypto/external/bsd/openssh/dist/sshkey.c Fri Aug 03 12:48:33 2018 +0000
+++ b/crypto/external/bsd/openssh/dist/sshkey.c Fri Aug 03 12:49:41 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sshkey.c,v 1.15 2018/08/03 04:32:12 kamil Exp $        */
+/*     $NetBSD: sshkey.c,v 1.16 2018/08/03 12:49:41 kre Exp $  */
 /* $OpenBSD: sshkey.c,v 1.64 2018/03/22 07:05:48 markus Exp $ */
 /*
  * Copyright (c) 2000, 2001 Markus Friedl.  All rights reserved.
@@ -26,7 +26,7 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 #include "includes.h"
-__RCSID("$NetBSD: sshkey.c,v 1.15 2018/08/03 04:32:12 kamil Exp $");
+__RCSID("$NetBSD: sshkey.c,v 1.16 2018/08/03 12:49:41 kre Exp $");
 
 #include <sys/types.h>
 #include <netinet/in.h>
@@ -1641,7 +1641,7 @@
 int
 sshkey_ecdsa_key_to_nid(EC_KEY *k)
 {
-       EC_GROUP *eg = NULL;
+       EC_GROUP *eg = NULL;            /* XXXGCC: unneeded init */
        int nids[] = {
                NID_X9_62_prime256v1,
                NID_secp384r1,



Home | Main Index | Thread Index | Old Index