summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKenny Root <kroot@google.com>2013-05-06 22:04:18 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2013-05-06 22:04:19 +0000
commit7b65c5f03d4a74846f9376158cd9b90529de11c1 (patch)
tree7ccd34d17a5977cd510cad941b8fc85bc8c6d1bb
parenta41da0416f165216cacddff29d7e1359dcda0d7d (diff)
parentcc73183fa6f5f6f9935307aacfbfc5d93a867a23 (diff)
downloadlibcore-7b65c5f03d4a74846f9376158cd9b90529de11c1.zip
libcore-7b65c5f03d4a74846f9376158cd9b90529de11c1.tar.gz
libcore-7b65c5f03d4a74846f9376158cd9b90529de11c1.tar.bz2
Merge "NativeCrypto: pull in copy of EmptyArray"
-rw-r--r--crypto/src/main/java/org/conscrypt/ClientHello.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/ClientKeyExchange.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/DigitalSignature.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/KeyManagerFactoryImpl.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/Logger.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/OpenSSLCipher.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/OpenSSLCipherRSA.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/SSLServerSocketFactoryImpl.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/SSLSessionImpl.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/SSLSocketFactoryImpl.java2
-rw-r--r--crypto/src/main/java/org/conscrypt/util/EmptyArray.java35
11 files changed, 45 insertions, 10 deletions
diff --git a/crypto/src/main/java/org/conscrypt/ClientHello.java b/crypto/src/main/java/org/conscrypt/ClientHello.java
index 5599579..26bfead 100644
--- a/crypto/src/main/java/org/conscrypt/ClientHello.java
+++ b/crypto/src/main/java/org/conscrypt/ClientHello.java
@@ -21,7 +21,7 @@ import java.io.IOException;
import java.security.SecureRandom;
import java.util.Arrays;
import libcore.io.Streams;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* Represents Client Hello message
diff --git a/crypto/src/main/java/org/conscrypt/ClientKeyExchange.java b/crypto/src/main/java/org/conscrypt/ClientKeyExchange.java
index b513342..2bee607 100644
--- a/crypto/src/main/java/org/conscrypt/ClientKeyExchange.java
+++ b/crypto/src/main/java/org/conscrypt/ClientKeyExchange.java
@@ -20,7 +20,7 @@ package org.conscrypt;
import java.io.IOException;
import java.math.BigInteger;
import libcore.io.Streams;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* Represents client key exchange message
diff --git a/crypto/src/main/java/org/conscrypt/DigitalSignature.java b/crypto/src/main/java/org/conscrypt/DigitalSignature.java
index 627e147..5b59542 100644
--- a/crypto/src/main/java/org/conscrypt/DigitalSignature.java
+++ b/crypto/src/main/java/org/conscrypt/DigitalSignature.java
@@ -30,7 +30,7 @@ import javax.crypto.Cipher;
import javax.crypto.IllegalBlockSizeException;
import javax.crypto.NoSuchPaddingException;
import javax.net.ssl.SSLException;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* This class represents Signature type, as described in TLS v 1.0 Protocol
diff --git a/crypto/src/main/java/org/conscrypt/KeyManagerFactoryImpl.java b/crypto/src/main/java/org/conscrypt/KeyManagerFactoryImpl.java
index f5cf781..a715890 100644
--- a/crypto/src/main/java/org/conscrypt/KeyManagerFactoryImpl.java
+++ b/crypto/src/main/java/org/conscrypt/KeyManagerFactoryImpl.java
@@ -29,7 +29,7 @@ import java.security.cert.CertificateException;
import javax.net.ssl.KeyManager;
import javax.net.ssl.KeyManagerFactorySpi;
import javax.net.ssl.ManagerFactoryParameters;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* KeyManagerFactory implementation.
diff --git a/crypto/src/main/java/org/conscrypt/Logger.java b/crypto/src/main/java/org/conscrypt/Logger.java
index 5161343..9241c8a 100644
--- a/crypto/src/main/java/org/conscrypt/Logger.java
+++ b/crypto/src/main/java/org/conscrypt/Logger.java
@@ -19,7 +19,7 @@ package org.conscrypt;
import java.io.PrintStream;
import java.util.Locale;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* This class provides debug logging for JSSE provider implementation
diff --git a/crypto/src/main/java/org/conscrypt/OpenSSLCipher.java b/crypto/src/main/java/org/conscrypt/OpenSSLCipher.java
index efc9036..632f9e2 100644
--- a/crypto/src/main/java/org/conscrypt/OpenSSLCipher.java
+++ b/crypto/src/main/java/org/conscrypt/OpenSSLCipher.java
@@ -40,7 +40,7 @@ import javax.crypto.SecretKey;
import javax.crypto.ShortBufferException;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
public abstract class OpenSSLCipher extends CipherSpi {
diff --git a/crypto/src/main/java/org/conscrypt/OpenSSLCipherRSA.java b/crypto/src/main/java/org/conscrypt/OpenSSLCipherRSA.java
index 1682143..36820af 100644
--- a/crypto/src/main/java/org/conscrypt/OpenSSLCipherRSA.java
+++ b/crypto/src/main/java/org/conscrypt/OpenSSLCipherRSA.java
@@ -40,7 +40,7 @@ import javax.crypto.IllegalBlockSizeException;
import javax.crypto.NoSuchPaddingException;
import javax.crypto.ShortBufferException;
import javax.crypto.spec.SecretKeySpec;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
public abstract class OpenSSLCipherRSA extends CipherSpi {
/**
diff --git a/crypto/src/main/java/org/conscrypt/SSLServerSocketFactoryImpl.java b/crypto/src/main/java/org/conscrypt/SSLServerSocketFactoryImpl.java
index b229b2d..5b16f85 100644
--- a/crypto/src/main/java/org/conscrypt/SSLServerSocketFactoryImpl.java
+++ b/crypto/src/main/java/org/conscrypt/SSLServerSocketFactoryImpl.java
@@ -22,7 +22,7 @@ import java.net.InetAddress;
import java.net.ServerSocket;
import java.security.KeyManagementException;
import javax.net.ssl.SSLServerSocketFactory;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* Implementation of SSLServerSocketFactory.
diff --git a/crypto/src/main/java/org/conscrypt/SSLSessionImpl.java b/crypto/src/main/java/org/conscrypt/SSLSessionImpl.java
index 0b69717..4014a28 100644
--- a/crypto/src/main/java/org/conscrypt/SSLSessionImpl.java
+++ b/crypto/src/main/java/org/conscrypt/SSLSessionImpl.java
@@ -29,7 +29,7 @@ import javax.net.ssl.SSLSession;
import javax.net.ssl.SSLSessionBindingEvent;
import javax.net.ssl.SSLSessionBindingListener;
import javax.net.ssl.SSLSessionContext;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
public final class SSLSessionImpl implements SSLSession, Cloneable {
diff --git a/crypto/src/main/java/org/conscrypt/SSLSocketFactoryImpl.java b/crypto/src/main/java/org/conscrypt/SSLSocketFactoryImpl.java
index 26203af..dc971ac 100644
--- a/crypto/src/main/java/org/conscrypt/SSLSocketFactoryImpl.java
+++ b/crypto/src/main/java/org/conscrypt/SSLSocketFactoryImpl.java
@@ -23,7 +23,7 @@ import java.net.Socket;
import java.net.UnknownHostException;
import java.security.KeyManagementException;
import javax.net.ssl.SSLSocketFactory;
-import libcore.util.EmptyArray;
+import org.conscrypt.util.EmptyArray;
/**
* Implementation of SSLSocketFactory.
diff --git a/crypto/src/main/java/org/conscrypt/util/EmptyArray.java b/crypto/src/main/java/org/conscrypt/util/EmptyArray.java
new file mode 100644
index 0000000..e474562
--- /dev/null
+++ b/crypto/src/main/java/org/conscrypt/util/EmptyArray.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2010 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+// Copied from libcore.util.EmptyArray
+
+package org.conscrypt.util;
+
+public final class EmptyArray {
+ private EmptyArray() {}
+
+ public static final boolean[] BOOLEAN = new boolean[0];
+ public static final byte[] BYTE = new byte[0];
+ public static final char[] CHAR = new char[0];
+ public static final double[] DOUBLE = new double[0];
+ public static final int[] INT = new int[0];
+
+ public static final Class<?>[] CLASS = new Class[0];
+ public static final Object[] OBJECT = new Object[0];
+ public static final String[] STRING = new String[0];
+ public static final Throwable[] THROWABLE = new Throwable[0];
+ public static final StackTraceElement[] STACK_TRACE_ELEMENT = new StackTraceElement[0];
+} \ No newline at end of file