Index: openssl/crypto/x509/by_dir.c |
=================================================================== |
--- openssl/crypto/x509/by_dir.c (revision 189610) |
+++ openssl/crypto/x509/by_dir.c (working copy) |
@@ -287,6 +287,8 @@ |
int ok=0; |
int i,j,k; |
unsigned long h; |
+ unsigned long hash_array[2]; |
+ int hash_index; |
BUF_MEM *b=NULL; |
X509_OBJECT stmp,*tmp; |
const char *postfix=""; |
@@ -323,6 +325,11 @@ |
ctx=(BY_DIR *)xl->method_data; |
h=X509_NAME_hash(name); |
+ hash_array[0]=h; |
Ryan Sleevi
2013/03/21 19:56:01
Why structured like this?
Why not
hash_array[0]=X
digit1
2013/03/21 21:23:31
That's not my code :-) I'll try to fix it nonethel
|
+ hash_array[1]=X509_NAME_hash_old(name); |
+ for (hash_index=0; hash_index < 2; hash_index++) |
Ryan Sleevi
2013/03/21 19:56:01
++hash_index
wtc
2013/03/21 22:41:49
Our C++ Style Guide only recommends using the
pre-
agl
2013/03/22 13:52:36
Long ago, post incrementing STL iterators was less
|
+ { |
+ h=hash_array[hash_index]; |
for (i=0; i < sk_BY_DIR_ENTRY_num(ctx->dirs); i++) |
{ |
BY_DIR_ENTRY *ent; |
@@ -476,6 +483,7 @@ |
goto finish; |
} |
} |
+ } |
finish: |
if (b != NULL) BUF_MEM_free(b); |
return(ok); |