Remove #ifdef's for IRIX_CC_BUG
[oweals/openssl.git] / crypto / bn / bn_lib.c
index b1e224bb4dc19bbcfec662057179b8860ea67c05..72c2cf0a3d08d668f8760f1d6df41887debe9c81 100644 (file)
@@ -65,7 +65,6 @@
 
 #include <assert.h>
 #include <limits.h>
-#include <stdio.h>
 #include "cryptlib.h"
 #include "bn_lcl.h"
 
@@ -324,6 +323,15 @@ static BN_ULONG *bn_expand_internal(const BIGNUM *b, int words)
                BNerr(BN_F_BN_EXPAND_INTERNAL,ERR_R_MALLOC_FAILURE);
                return(NULL);
                }
+#ifdef PURIFY
+       /* Valgrind complains in BN_consttime_swap because we process the whole
+        * array even if it's not initialised yet. This doesn't matter in that
+        * function - what's important is constant time operation (we're not
+        * actually going to use the data)
+       */
+       memset(a, 0, sizeof(BN_ULONG)*words);
+#endif
+
 #if 1
        B=b->d;
        /* Check if the previous number needs to be copied */