Support functions usage without NSSCertDB instance
Some NSS Certificate Database functions that return information about certificates are expensive and should not be called on the UI thread. This CL is part of the effort of normalizing the way of gathering this certificates information to make sure it is gathered on a worker thread. To call these functions on a worker thread, they should not depend on NSSCertDatabase instances, so if the instances goes out of scope, the code does not run into undefined behaviour. In this CL some NSS Certificate Database functions that does not depend on database instances are converted to static to be able to use them safely inside worker threads. 1- net_unittests --gtest_filter=NSSCertDatabase* 2- unittests --gtest_filter=CertificateManagerModel* Bug: chromium:1043083, chromium:1012430 Test: Change-Id: I63a1157c5d92b44f8d5252e9475104a1adfa8376 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2054090Reviewed-by:Ryan Sleevi <rsleevi@chromium.org> Reviewed-by:
Matt Mueller <mattm@chromium.org> Reviewed-by:
Pavol Marko <pmarko@chromium.org> Commit-Queue: Omar Morsi <omorsi@google.com> Cr-Commit-Position: refs/heads/master@{#743023}
Showing
Please register or sign in to comment