[openssl-commits] [openssl] master update

Rich Salz rsalz at openssl.org
Sat Jan 24 21:35:29 UTC 2015


The branch master has been updated
       via  8de24b792743d11e1d5a0dcd336a49368750c577 (commit)
      from  c436e05bdc7f49985a750df64122c960240b3ae1 (commit)


- Log -----------------------------------------------------------------
commit 8de24b792743d11e1d5a0dcd336a49368750c577
Author: Rich Salz <rsalz at openssl.org>
Date:   Sat Jan 24 16:35:07 2015 -0500

    undef cleanup: use memmove
    
    Reviewed-by: Andy Polyakov <appro at openssl.org>

-----------------------------------------------------------------------

Summary of changes:
 crypto/stack/stack.c |   21 ---------------------
 1 file changed, 21 deletions(-)

diff --git a/crypto/stack/stack.c b/crypto/stack/stack.c
index 47457c7..758ace9 100644
--- a/crypto/stack/stack.c
+++ b/crypto/stack/stack.c
@@ -55,17 +55,6 @@
  * copied and put under another distribution licence
  * [including the GNU Public Licence.]
  */
-
-/*-
- * Code for stacks
- * Author - Eric Young v 1.0
- * 1.2 eay 12-Mar-97 -  Modified sk_find so that it _DOES_ return the
- *                      lowest index for the searched item.
- *
- * 1.1 eay - Take from netdb and added to SSLeay
- *
- * 1.0 eay - First version 29/07/92
- */
 #include <stdio.h>
 #include "cryptlib.h"
 #include <openssl/stack.h>
@@ -193,18 +182,8 @@ int sk_insert(_STACK *st, void *data, int loc)
     if ((loc >= (int)st->num) || (loc < 0))
         st->data[st->num] = data;
     else {
-        int i;
-        char **f, **t;
-
-        f = st->data;
-        t = &(st->data[1]);
-        for (i = st->num; i >= loc; i--)
-            t[i] = f[i];
-
-#ifdef undef                    /* no memmove on sunos :-( */
         memmove(&(st->data[loc + 1]),
                 &(st->data[loc]), sizeof(char *) * (st->num - loc));
-#endif
         st->data[loc] = data;
     }
     st->num++;


More information about the openssl-commits mailing list