OLD | NEW |
(Empty) | |
| 1 diff -burN android-openssl.orig/crypto/x509/by_dir.c android-openssl/crypto/x509
/by_dir.c |
| 2 --- android-openssl.orig/crypto/x509/by_dir.c 2013-03-25 11:30:17.775049611 +0
100 |
| 3 +++ android-openssl/crypto/x509/by_dir.c 2013-03-25 11:31:52.936070192 +0
100 |
| 4 @@ -287,6 +287,8 @@ |
| 5 int ok=0; |
| 6 int i,j,k; |
| 7 unsigned long h; |
| 8 + unsigned long hash_array[2]; |
| 9 + int hash_index; |
| 10 BUF_MEM *b=NULL; |
| 11 X509_OBJECT stmp,*tmp; |
| 12 const char *postfix=""; |
| 13 @@ -322,7 +324,11 @@ |
| 14 |
| 15 ctx=(BY_DIR *)xl->method_data; |
| 16 |
| 17 - h=X509_NAME_hash(name); |
| 18 + hash_array[0]=X509_NAME_hash(name); |
| 19 + hash_array[1]=X509_NAME_hash_old(name); |
| 20 + for (hash_index=0; hash_index < 2; ++hash_index) |
| 21 + { |
| 22 + h=hash_array[hash_index]; |
| 23 for (i=0; i < sk_BY_DIR_ENTRY_num(ctx->dirs); i++) |
| 24 { |
| 25 BY_DIR_ENTRY *ent; |
| 26 @@ -476,6 +482,7 @@ |
| 27 goto finish; |
| 28 } |
| 29 } |
| 30 + } |
| 31 finish: |
| 32 if (b != NULL) BUF_MEM_free(b); |
| 33 return(ok); |
OLD | NEW |