diff options
author | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-28 00:32:10 +0000 |
---|---|---|
committer | wtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-01-28 00:32:10 +0000 |
commit | c2a4c3d9954148e090332e29a2d88f64dffe9a3a (patch) | |
tree | 6b2449ec85d35e7ac9aab8c539536c8199c473e7 /net/socket | |
parent | e09cfd8679ef12b16e17a1d246a1057d24c6132c (diff) | |
download | chromium_src-c2a4c3d9954148e090332e29a2d88f64dffe9a3a.zip chromium_src-c2a4c3d9954148e090332e29a2d88f64dffe9a3a.tar.gz chromium_src-c2a4c3d9954148e090332e29a2d88f64dffe9a3a.tar.bz2 |
Use the USE_NSS macro to help porting to FreeBSD, OpenBSD, etc.
Fix cpplint nits.
R=evan,pvalchev
BUG=none
TEST=No compilation errors.
Review URL: http://codereview.chromium.org/558008
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@37358 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/socket')
-rw-r--r-- | net/socket/ssl_test_util.cc | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/net/socket/ssl_test_util.cc b/net/socket/ssl_test_util.cc index cde21f3..60b1f1f 100644 --- a/net/socket/ssl_test_util.cc +++ b/net/socket/ssl_test_util.cc @@ -2,18 +2,18 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. +#include "net/socket/ssl_test_util.h" + #include <algorithm> #include <string> #include <vector> -#include "net/socket/ssl_test_util.h" - #include "build/build_config.h" #if defined(OS_WIN) #include <windows.h> #include <wincrypt.h> -#elif defined(OS_LINUX) +#elif defined(USE_NSS) #include <nspr.h> #include <nss.h> #include <secerr.h> @@ -44,7 +44,7 @@ namespace { -#if defined(OS_LINUX) +#if defined(USE_NSS) static CERTCertificate* LoadTemporaryCert(const FilePath& filename) { base::EnsureNSSInit(); @@ -138,7 +138,7 @@ TestServerLauncher::TestServerLauncher() : process_handle_( forking_(false), connection_attempts_(kDefaultTestConnectionAttempts), connection_timeout_(kDefaultTestConnectionTimeout) -#if defined(OS_LINUX) +#if defined(USE_NSS) , cert_(NULL) #endif { @@ -151,7 +151,7 @@ TestServerLauncher::TestServerLauncher(int connection_attempts, forking_(false), connection_attempts_(connection_attempts), connection_timeout_(connection_timeout) -#if defined(OS_LINUX) +#if defined(USE_NSS) , cert_(NULL) #endif { @@ -353,7 +353,7 @@ bool TestServerLauncher::Stop() { } TestServerLauncher::~TestServerLauncher() { -#if defined(OS_LINUX) +#if defined(USE_NSS) if (cert_) CERT_DestroyCertificate(reinterpret_cast<CERTCertificate*>(cert_)); #elif defined(OS_MACOSX) @@ -381,7 +381,7 @@ FilePath TestServerLauncher::GetExpiredCertPath() { } bool TestServerLauncher::LoadTestRootCert() { -#if defined(OS_LINUX) +#if defined(USE_NSS) if (cert_) return true; |