Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(461)

Side by Side Diff: net/third_party/nss/patches/fixpk11symbollookup.patch

Issue 962593002: Use dlsym(RTLD_DEFAULT) instead of dlsym(dlopen(NULL)) in aesgcmchromium.patch. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address Ryan's comments. Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 diff --git a/net/third_party/nss/ssl/ssl3con.c b/net/third_party/nss/ssl/ssl3con .c
2 index ffb757a..91a1f1e 100644
3 --- a/net/third_party/nss/ssl/ssl3con.c
4 +++ b/net/third_party/nss/ssl/ssl3con.c
5 @@ -8,6 +8,7 @@
6
7 /* TODO(ekr): Implement HelloVerifyRequest on server side. OK for now. */
8
9 +#define _GNU_SOURCE 1
10 #include "cert.h"
11 #include "ssl.h"
12 #include "cryptohi.h" /* for DSAU_ stuff */
13 @@ -1884,14 +1885,8 @@ ssl3_ResolvePK11CryptFunctions(void)
14 #ifdef LINUX
15 /* On Linux we use the system NSS libraries. Look up the PK11_Encrypt and
16 * PK11_Decrypt functions at run time. */
17 - void *handle = dlopen(NULL, RTLD_LAZY);
18 - if (!handle) {
19 - PORT_SetError(SEC_ERROR_LIBRARY_FAILURE);
20 - return PR_FAILURE;
21 - }
22 - pk11_encrypt = (PK11CryptFcn)dlsym(handle, "PK11_Encrypt");
23 - pk11_decrypt = (PK11CryptFcn)dlsym(handle, "PK11_Decrypt");
24 - dlclose(handle);
25 + pk11_encrypt = (PK11CryptFcn)dlsym(RTLD_DEFAULT, "PK11_Encrypt");
26 + pk11_decrypt = (PK11CryptFcn)dlsym(RTLD_DEFAULT, "PK11_Decrypt");
27 return PR_SUCCESS;
28 #else
29 /* On other platforms we use our own copy of NSS. PK11_Encrypt and
30 --
31 2.2.0.rc0.207.ga3a616c
32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698