OSDN Git Service
Elliott Hughes [Thu, 22 Oct 2009 00:09:13 +0000 (17:09 -0700)]
Remove OSNetworkSystem.receiveStream.
Harmony removed this some time ago, and -- if we change our read/readDirect
implementations slightly -- we can too.
I've also added some bounds checking in the Java so we don't ask native code
to perform a buffer overrun for us.
I've also rewritten the native readSocketImpl to use GetByteArrayElements and
ReleaseByteArrayElements rather than its own custom stack/heap allocation and
arbitrary 64KiB limit. (As far as I can tell from the harmony history, the
limit dates from when they always read into an on-stack buffer, and was never
removed.)
I've also brought us in line with harmony so we only pass 'address' to
readDirect, rather than 'address' and 'offset'.
I've changed SocketTest to match upstream and -- since they pulled out some
of the tests into a new file -- I've added their UnixSocketTest so we don't
miss out. Our old SocketTest's test_getInputStream is the only test my new
code doesn't pass, but I think the old SocketTest was broken and the new
SocketTest/UnixSocketTest is correct.
I've also brought us back into line with harmony's MulticastSocketTest. With
the up-to-date tests, the new code behaves the same as the old code. (With
our old tests, the new code fails the joinGroup test with a
NullPointerException instead of a junit comparison failure.)
Android (Google) Code Review [Thu, 22 Oct 2009 17:55:38 +0000 (13:55 -0400)]
Merge change Ibeb7d4a2
* changes:
Cleaning up synchronization in Logger.
Jesse Wilson [Wed, 21 Oct 2009 21:57:48 +0000 (14:57 -0700)]
Cleaning up synchronization in Logger.
Formerly any logged message would require synchronization on the shared
global lock to access the root logger's handlers. This change replaces
synchronization on loggers with a combination of copy-on-write and
volatile fields.
Also moving handler initialization from lazy to eager - the code has
moved from initHandlers() to setManager().
Also tidying up the info(), severe() type methods to delegate to avoid
unnecessary duplication.
Android (Google) Code Review [Thu, 22 Oct 2009 14:34:55 +0000 (10:34 -0400)]
Merge change I3d8565f0
* changes:
Collation.getSortKey returns keys generated by a different algorithm
Android (Google) Code Review [Thu, 22 Oct 2009 14:22:32 +0000 (10:22 -0400)]
Merge change I5ea630ca
* changes:
Use a binary search for sparse switch statements.
Android (Google) Code Review [Thu, 22 Oct 2009 14:19:51 +0000 (10:19 -0400)]
Merge change Id1f4cf7b
* changes:
Clear pending exception before throwing a new one.
Andy McFadden [Wed, 21 Oct 2009 23:59:31 +0000 (16:59 -0700)]
Use a binary search for sparse switch statements.
Added a couple of edge cases to test 015.
For bug
2119870.
Andy McFadden [Wed, 21 Oct 2009 22:36:48 +0000 (15:36 -0700)]
Clear pending exception before throwing a new one.
The JNI helper function that throws an exception calls FindClass, which
isn't allowed if an exception is currently pending. Some of our code
called this when an operation failed without noting that the thing that
failed already threw an exception; this caused the VM to blow up in a
rather unhelpful way.
We now log the class name and optional message from the original
exception, clear it, and then allocate & throw the new one.
For bug
2141867.
Android (Google) Code Review [Wed, 21 Oct 2009 20:05:07 +0000 (16:05 -0400)]
Merge change Id434c469
* changes:
More OSNetworkSystem cleanup.
Elliott Hughes [Wed, 21 Oct 2009 05:58:23 +0000 (22:58 -0700)]
More OSNetworkSystem cleanup.
Rewrite OSNetworkSystem.connect in terms of connectStreamWithTimeoutSocketImpl
in Java rather than in native code. Remove OSNetworkSystem.connectSocketImpl.
Make INetworkSystem.connect void, since the return value is always 0.
Use TEMP_FAILURE_RETRY rather than explicit do loops to retry interrupted
system calls.
Fix peekDatagramImpl to actually update the byte[] in the passed-in
InetAddress.
Stop pulling the int fd out of the FileDescriptor each time round the loop
in sendStreamImpl and sendDatagramImpl2.
More tiny steps towards eliminating the SOCKERR_ nonsense in favor of errno.
Prefer sizeof(variable) to sizeof(type).
Remove a few more superfluous "struct" keywords.
Android (Google) Code Review [Wed, 21 Oct 2009 16:53:08 +0000 (12:53 -0400)]
Merge change Iacd79b8a
* changes:
Avoid shadowing fields from the superclass testcase.
Jesse Wilson [Wed, 21 Oct 2009 01:49:47 +0000 (18:49 -0700)]
Avoid shadowing fields from the superclass testcase.
Android (Google) Code Review [Wed, 21 Oct 2009 01:10:03 +0000 (21:10 -0400)]
Merge change I54b596ca
* changes:
Expose the portable "strerror_r" used by jniThrowIOException.
Elliott Hughes [Tue, 20 Oct 2009 23:59:01 +0000 (16:59 -0700)]
Expose the portable "strerror_r" used by jniThrowIOException.
Also add one example caller I used to test this, and update the
libnativehelper README file.
Android (Google) Code Review [Tue, 20 Oct 2009 23:13:32 +0000 (19:13 -0400)]
Merge change Ib28d3a82
* changes:
Don't over flush the code cache at startup time.
Ben Cheng [Tue, 20 Oct 2009 22:57:28 +0000 (15:57 -0700)]
Don't over flush the code cache at startup time.
Suspected that the kernel is having issues flushing cachelines for mmapped
pages that haven't been written to.
Android (Google) Code Review [Tue, 20 Oct 2009 22:25:32 +0000 (18:25 -0400)]
Merge change Iadbb9163
* changes:
Implement JNI "weak global" references.
Android (Google) Code Review [Tue, 20 Oct 2009 20:31:38 +0000 (16:31 -0400)]
Merge change Ia8e64a7c
* changes:
Fix an invoke-interface bug that manifests itself with thread state warnings.
Android (Google) Code Review [Tue, 20 Oct 2009 20:24:27 +0000 (16:24 -0400)]
Merge change I9b12eeb5
* changes:
Applying PrefsTester to PreferenceChangeEventTest to manage side effects.
Android (Google) Code Review [Tue, 20 Oct 2009 20:23:45 +0000 (16:23 -0400)]
Merge change Id752d5fb
* changes:
Including cert store location for test runner.
Ben Cheng [Tue, 20 Oct 2009 20:01:36 +0000 (13:01 -0700)]
Fix an invoke-interface bug that manifests itself with thread state warnings.
r12 is a scratch register and apparently gcc 4.4 starts to actively use it in
dvmFindInterfaceMethodInCache, the very function that the original live value
is being protected around. This results in useless values setup in the chaining
cell and increases the chances to patch the cell (thus the suspend-all
requests).
Add verbose names for new JIT-related suspend reasons.
With all these changes, the thread state warning will still occur but much less
frequently.
bug
2194174.
Andy McFadden [Fri, 25 Sep 2009 17:42:15 +0000 (10:42 -0700)]
Implement JNI "weak global" references.
The VM now supports the NewWeakGlobalRef and DeleteWeakGlobalRef calls,
which create a kind of weak reference that's directly visible to native
code. While the JNI spec says that these can be used directly, the only
safe way to use them is to convert them to a strong local or global
reference first, so this is enforced.
The net result is very similar to manually creating a global reference to
a WeakReference object and manipulating it with method calls from native
code, but the JNI calls are faster and more convenient.
Jesse Wilson [Tue, 20 Oct 2009 18:13:20 +0000 (11:13 -0700)]
Including cert store location for test runner.
This helps to avoid bad interactions between tests that rely
on the "java.home" property for different things. Preferences
tests tend to change it (to the writable temp directory), but
the certs tests fall back to it for the trust store.
See also TrustManagerFactoryImpl.java.
Dan Bornstein [Fri, 16 Oct 2009 17:51:23 +0000 (10:51 -0700)]
Another couple of tweaks in my attempt to make a sane host build.
Change-Id: I49938c6aa933cca19874432b127ad9b1b49e3e79
Jesse Wilson [Tue, 20 Oct 2009 17:46:25 +0000 (10:46 -0700)]
Applying PrefsTester to PreferenceChangeEventTest to manage side effects.
Android (Google) Code Review [Tue, 20 Oct 2009 16:14:41 +0000 (12:14 -0400)]
Merge change I73fd1714
* changes:
Fix OSNetworkSystem.acceptImpl error handling; additional clean-up.
Urs Grob [Tue, 8 Sep 2009 18:13:49 +0000 (20:13 +0200)]
Collation.getSortKey returns keys generated by a different algorithm
This test tested implementation details. This change makes the test only check specified behavior.
Note: The resulting key is incompatible with a key returned by the RI. that's the downside of using icu.
But there's also an upside: ICU compresses the sorting key that gets returned. This increases performance
when comparing the keys.
BUG=
1635900
Android (Google) Code Review [Tue, 20 Oct 2009 07:08:44 +0000 (03:08 -0400)]
Merge change I7cc0fe4d
* changes:
rightsize StringBuilders for arrays; see bug
2135223
Android (Google) Code Review [Tue, 20 Oct 2009 02:46:30 +0000 (22:46 -0400)]
Merge change Ice8c6c56
* changes:
Removing caching of file canonical path caching, and fixing NIO tests.
Jesse Wilson [Tue, 20 Oct 2009 00:40:29 +0000 (17:40 -0700)]
Removing caching of file canonical path caching, and fixing NIO tests.
I checked in some regressions in the NIO test cases with the NIO patch;
this addresses those problems.
Elliott Hughes [Mon, 19 Oct 2009 23:36:13 +0000 (16:36 -0700)]
Fix OSNetworkSystem.acceptImpl error handling; additional clean-up.
The main reason for this patch is that acceptImpl was checking the wrong
return code.
I've also removed the BADSOCKET and UNKNOWNSOCKET errors because they were
being used interchangeably with the BADDESC error and weren't genuinely
meaningful.
I've also removed the bogus checks for 0 as a file descriptor, which is
perfectly valid (if unlikely).
I've factored this common snippet out.
Android (Google) Code Review [Tue, 20 Oct 2009 00:21:35 +0000 (20:21 -0400)]
Merge change I36117487
* changes:
Tidy up Logger in preparation for optimizations.
Jesse Wilson [Mon, 19 Oct 2009 22:00:03 +0000 (15:00 -0700)]
Tidy up Logger in preparation for optimizations.
Highlights:
- Clean up documentation. Moved internal docs from variable use site
to declaration site, especially for special cases around null.
- Move default variable values to declaration
- Move methods requiring LogManager synchronization to LogManager.
This includes setLevelImpl(), forceChildsToInherit(),
internalSetParent() and getLoggerWithRes().
- flip "if (null == foo)" to "if (foo == null)" for readability
- Rename updateResourceBundle to initResourceBundle. Made method
non-static.
- Rename initHandler to initHandlers; changed the method to
short circuit on negative 'handlerInited' cases.
- Flipped "internalIsLoggable" methods to short-circuit.
- Expose variables used by LogManager as package-private. For example,
the childs variable is only used by LogManager, but previously it
went through the Logger class each time it was used.
Android (Google) Code Review [Mon, 19 Oct 2009 21:01:25 +0000 (17:01 -0400)]
Merge change I1f575e9e
* changes:
Improve error handling in InetAddress native code.
Elliott Hughes [Sat, 17 Oct 2009 00:25:34 +0000 (17:25 -0700)]
Improve error handling in InetAddress native code.
Fix a bug where we changed the return values of functions such
as byteArrayToSocketAddress without changing the logic in the
callers that's supposed to distinguish success and failure.
For simplicity, I've switch all of these functions over to
returning bool, and I've gone through all the callers to ensure
we're using the right check now. (This is the majority of the
diff.)
Also switch to throwing IllegalArgumentException instead of SocketException
when we find ourselves with a bad byte[] --- before we were throwing
a checked exception we weren't allowed to (from native code, which
can't actually be checked statically) and then trying to cover up
in Java.
I've also simply removed one case where we were trying to mask an
OutOfMemoryError with a SocketException.
I also removed dead code in socketAddressToString: this function's
sole caller always passed false for withPort. This makes the
temporary variable and the copying (which was unsafe) unnecessary.
In instances where I was already changing the code, I've removed
bogus "handle == 0" failures, but I'll come back and remove all
the other instances in another patch.
Since I was in connectSocketImpl, I've removed the dead second half
of that method.
Jesse Wilson [Fri, 16 Oct 2009 21:55:49 +0000 (14:55 -0700)]
rightsize StringBuilders for arrays; see bug
2135223
Android (Google) Code Review [Fri, 16 Oct 2009 20:43:35 +0000 (16:43 -0400)]
Merge change I2e354493
* changes:
Update NIO and NIO char packages to Harmony 802921.
Jesse Wilson [Thu, 15 Oct 2009 22:01:39 +0000 (15:01 -0700)]
Update NIO and NIO char packages to Harmony 802921.
Notable changes:
- We don't use Harmony's new indexing for SelectorImpl. See the long bug
thread on Harmony's site, https://issues.apache.org/jira/browse/HARMONY-6312
This patch includes the latest Harmony changes to SelectorImpl, which
have been optimized since this patch was first created.
- Several uses of StringBuffer updated to use StringBuilder
- CharBuffer.read implementation changes
- Additional checking in CharsetEncoder
- Some inner classes made static
- Harmony changed their Charset impl from ICU to Java. We're sticking with ICU.
- Harmony added support for epoll. We're sticking with standard 'poll'.
commit
2ed6cb602a52f4681afbf1348928f1b0c36d914d
Merge:
8a74fca bcc5ec7
Author: Jesse Wilson <jessewilson@google.com>
Date: Fri Aug 14 15:14:10 2009 -0700
Merge branch 'nio_802921' into nio_dalvik
Conflicts:
libcore/nio/.classpath
libcore/nio/META-INF/MANIFEST.MF
libcore/nio/build.xml
libcore/nio/make/exclude.linux.x86.drl
libcore/nio/make/exclude.linux.x86.ibm
libcore/nio/make/exclude.linux.x86_64.drl
libcore/nio/src/main/java/java/nio/BaseByteBuffer.java
libcore/nio/src/main/java/java/nio/Buffer.java
libcore/nio/src/main/java/java/nio/BufferOverflowException.java
libcore/nio/src/main/java/java/nio/BufferUnderflowException.java
libcore/nio/src/main/java/java/nio/ByteBuffer.java
libcore/nio/src/main/java/java/nio/ByteOrder.java
libcore/nio/src/main/java/java/nio/CharArrayBuffer.java
libcore/nio/src/main/java/java/nio/CharBuffer.java
libcore/nio/src/main/java/java/nio/CharSequenceAdapter.java
libcore/nio/src/main/java/java/nio/CharToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/DirectByteBuffer.java
libcore/nio/src/main/java/java/nio/DirectByteBuffers.java
libcore/nio/src/main/java/java/nio/DoubleArrayBuffer.java
libcore/nio/src/main/java/java/nio/DoubleBuffer.java
libcore/nio/src/main/java/java/nio/DoubleToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/FloatArrayBuffer.java
libcore/nio/src/main/java/java/nio/FloatBuffer.java
libcore/nio/src/main/java/java/nio/FloatToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/HeapByteBuffer.java
libcore/nio/src/main/java/java/nio/IntArrayBuffer.java
libcore/nio/src/main/java/java/nio/IntBuffer.java
libcore/nio/src/main/java/java/nio/IntToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/InvalidMarkException.java
libcore/nio/src/main/java/java/nio/LongArrayBuffer.java
libcore/nio/src/main/java/java/nio/LongBuffer.java
libcore/nio/src/main/java/java/nio/LongToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/MappedByteBuffer.java
libcore/nio/src/main/java/java/nio/MappedByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/ReadOnlyBufferException.java
libcore/nio/src/main/java/java/nio/ReadOnlyCharArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyDirectByteBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyDoubleArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyFloatArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyHeapByteBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyIntArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyLongArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadOnlyShortArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteCharArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteDirectByteBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteDoubleArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteFloatArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteHeapByteBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteIntArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteLongArrayBuffer.java
libcore/nio/src/main/java/java/nio/ReadWriteShortArrayBuffer.java
libcore/nio/src/main/java/java/nio/ShortArrayBuffer.java
libcore/nio/src/main/java/java/nio/ShortBuffer.java
libcore/nio/src/main/java/java/nio/ShortToByteBufferAdapter.java
libcore/nio/src/main/java/java/nio/channels/AlreadyConnectedException.java
libcore/nio/src/main/java/java/nio/channels/AsynchronousCloseException.java
libcore/nio/src/main/java/java/nio/channels/ByteChannel.java
libcore/nio/src/main/java/java/nio/channels/CancelledKeyException.java
libcore/nio/src/main/java/java/nio/channels/Channel.java
libcore/nio/src/main/java/java/nio/channels/Channels.java
libcore/nio/src/main/java/java/nio/channels/ClosedByInterruptException.java
libcore/nio/src/main/java/java/nio/channels/ClosedChannelException.java
libcore/nio/src/main/java/java/nio/channels/ClosedSelectorException.java
libcore/nio/src/main/java/java/nio/channels/ConnectionPendingException.java
libcore/nio/src/main/java/java/nio/channels/DatagramChannel.java
libcore/nio/src/main/java/java/nio/channels/FileChannel.java
libcore/nio/src/main/java/java/nio/channels/FileLock.java
libcore/nio/src/main/java/java/nio/channels/FileLockInterruptionException.java
libcore/nio/src/main/java/java/nio/channels/GatheringByteChannel.java
libcore/nio/src/main/java/java/nio/channels/IllegalBlockingModeException.java
libcore/nio/src/main/java/java/nio/channels/IllegalSelectorException.java
libcore/nio/src/main/java/java/nio/channels/InterruptibleChannel.java
libcore/nio/src/main/java/java/nio/channels/NoConnectionPendingException.java
libcore/nio/src/main/java/java/nio/channels/NonReadableChannelException.java
libcore/nio/src/main/java/java/nio/channels/NonWritableChannelException.java
libcore/nio/src/main/java/java/nio/channels/NotYetBoundException.java
libcore/nio/src/main/java/java/nio/channels/NotYetConnectedException.java
libcore/nio/src/main/java/java/nio/channels/OverlappingFileLockException.java
libcore/nio/src/main/java/java/nio/channels/Pipe.java
libcore/nio/src/main/java/java/nio/channels/ReadableByteChannel.java
libcore/nio/src/main/java/java/nio/channels/ScatteringByteChannel.java
libcore/nio/src/main/java/java/nio/channels/SelectableChannel.java
libcore/nio/src/main/java/java/nio/channels/SelectionKey.java
libcore/nio/src/main/java/java/nio/channels/Selector.java
libcore/nio/src/main/java/java/nio/channels/ServerSocketChannel.java
libcore/nio/src/main/java/java/nio/channels/SocketChannel.java
libcore/nio/src/main/java/java/nio/channels/UnresolvedAddressException.java
libcore/nio/src/main/java/java/nio/channels/UnsupportedAddressTypeException.java
libcore/nio/src/main/java/java/nio/channels/WritableByteChannel.java
libcore/nio/src/main/java/java/nio/channels/spi/AbstractInterruptibleChannel.java
libcore/nio/src/main/java/java/nio/channels/spi/AbstractSelectableChannel.java
libcore/nio/src/main/java/java/nio/channels/spi/AbstractSelectionKey.java
libcore/nio/src/main/java/java/nio/channels/spi/AbstractSelector.java
libcore/nio/src/main/java/java/nio/channels/spi/SelectorProvider.java
libcore/nio/src/main/java/org/apache/harmony/nio/AddressUtil.java
libcore/nio/src/main/java/org/apache/harmony/nio/FileChannelFactory.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/DatagramChannelImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/DirectBuffer.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/FileChannelImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/FileLockImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/IOUtil.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/MappedByteBufferFactory.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/ReadOnlyFileChannel.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/ReadWriteFileChannel.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/SelectorImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/SelectorProviderImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/SocketChannelImpl.java
libcore/nio/src/main/java/org/apache/harmony/nio/internal/WriteOnlyFileChannel.java
libcore/nio/src/main/native/nio/shared/DirectBufferUtil.c
libcore/nio/src/main/native/nio/unix/exports.txt
libcore/nio/src/main/native/nio/unix/makefile
libcore/nio/src/main/native/nio/windows/makefile
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/BufferOverflowExceptionTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/BufferUnderflowExceptionTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/CharBufferTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/FloatBufferTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/InvalidMarkExceptionTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/MappedByteBufferTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/ReadOnlyBufferExceptionTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/DatagramChannelTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/FileChannelLockingTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/FileChannelTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/FileChannelWin32OnlyTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/FileLockTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/ServerSocketChannelTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/SocketChannelTest.java
libcore/nio/src/test/java/org/apache/harmony/nio/tests/java/nio/channels/spi/AbstractSelectableChannelTest.java
libcore/nio_char/.classpath
libcore/nio_char/META-INF/MANIFEST.MF
libcore/nio_char/build.xml
libcore/nio_char/src/main/java/java/nio/charset/CharacterCodingException.java
libcore/nio_char/src/main/java/java/nio/charset/Charset.java
libcore/nio_char/src/main/java/java/nio/charset/CharsetDecoder.java
libcore/nio_char/src/main/java/java/nio/charset/CharsetEncoder.java
libcore/nio_char/src/main/java/java/nio/charset/CoderMalfunctionError.java
libcore/nio_char/src/main/java/java/nio/charset/CoderResult.java
libcore/nio_char/src/main/java/java/nio/charset/CodingErrorAction.java
libcore/nio_char/src/main/java/java/nio/charset/IllegalCharsetNameException.java
libcore/nio_char/src/main/java/java/nio/charset/MalformedInputException.java
libcore/nio_char/src/main/java/java/nio/charset/UnmappableCharacterException.java
libcore/nio_char/src/main/java/java/nio/charset/UnsupportedCharsetException.java
libcore/nio_char/src/test/java/org/apache/harmony/nio_char/tests/java/nio/charset/CharsetDecoderTest.java
libcore/nio_char/src/test/java/org/apache/harmony/nio_char/tests/java/nio/charset/CharsetEncoderTest.java
libcore/nio_char/src/test/java/org/apache/harmony/nio_char/tests/java/nio/charset/CharsetTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/ASCCharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/CharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/CharsetEncoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/CharsetProviderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/CharsetTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/GBCharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/GBCharsetEncoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/ISOCharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTF16BECharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTF16CharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTF16CharsetEncoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTF16LECharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTFCharsetDecoderTest.java
libcore/nio_char/src/test/java/tests/api/java/nio/charset/UTFCharsetEncoderTest.java
commit
8a74fca0d85c82a9d02a83d00fd028d9b09755f7
Author: Jesse Wilson <jessewilson@google.com>
Date: Thu Aug 13 16:03:25 2009 -0700
Dalvik Nio, Nio char
commit
bcc5ec78806787fbecab742e716fc0d63bcece5c
Author: Jesse Wilson <jessewilson@google.com>
Date: Thu Aug 13 16:01:06 2009 -0700
Nio, nio char 802921
commit
fc1e09e74aec8e49e0e23f13643deed1e9112af4
Author: Jesse Wilson <jessewilson@google.com>
Date: Thu Aug 13 15:48:17 2009 -0700
Nio, nio char 527399
Jesse Wilson [Fri, 16 Oct 2009 00:30:27 +0000 (17:30 -0700)]
Respond to impossible CloneNotSupportedExceptions with AssertionErrors.
See bug
2183132.
Android (Google) Code Review [Fri, 16 Oct 2009 15:23:14 +0000 (11:23 -0400)]
Merge change Id26b232b
* changes:
Fix Float.valueOf(String) OutOfMemoryExceptions.
Elliott Hughes [Thu, 15 Oct 2009 23:50:10 +0000 (16:50 -0700)]
Fix Float.valueOf(String) OutOfMemoryExceptions.
Apply http://issues.apache.org/jira/browse/HARMONY-6261, which was missed in
our recent luni merge.
Bug:
1957904
Android (Google) Code Review [Thu, 15 Oct 2009 22:31:59 +0000 (18:31 -0400)]
Merge change Iccd6c010
* changes:
Make the traige process for self-verification found divergence easier.
Ben Cheng [Thu, 15 Oct 2009 21:52:45 +0000 (14:52 -0700)]
Make the traige process for self-verification found divergence easier.
1. Automatically replay the code compilation with verbose mode turned on for
the offending compilation.
3. Mark the registers with divergence explicitly.
2. Print accurate operand names using the dataflow attributes. Constant values
are still printed for reference only.
3. Fixed a few correctness/style issues in self-verification code.
Jesse Wilson [Thu, 15 Oct 2009 20:45:21 +0000 (13:45 -0700)]
am
8673ee75: am
9a35ef1b: Guarantee deflaters get cleaned up, even if subclassed.
Merge commit '
8673ee75052e7398aa6f5925e968d6a0b2419be8'
* commit '
8673ee75052e7398aa6f5925e968d6a0b2419be8':
Guarantee deflaters get cleaned up, even if subclassed.
Jesse Wilson [Thu, 15 Oct 2009 20:36:21 +0000 (13:36 -0700)]
am
9a35ef1b: Guarantee deflaters get cleaned up, even if subclassed.
Merge commit '
9a35ef1b4b196f0479054993ab0eabac416c5214' into eclair-mr2-plus-aosp
* commit '
9a35ef1b4b196f0479054993ab0eabac416c5214':
Guarantee deflaters get cleaned up, even if subclassed.
Android (Google) Code Review [Thu, 15 Oct 2009 19:04:24 +0000 (15:04 -0400)]
Merge change I581bed77
* changes:
Add a memory barrier.
Jesse Wilson [Thu, 15 Oct 2009 18:46:52 +0000 (11:46 -0700)]
Guarantee deflaters get cleaned up, even if subclassed.
See bug
2186927
Android (Google) Code Review [Thu, 15 Oct 2009 18:28:09 +0000 (14:28 -0400)]
Merge change I11b31b39
* changes:
Fix icu4jni Resources ("Locale") to not expose its internals.
Andy McFadden [Thu, 15 Oct 2009 18:24:54 +0000 (11:24 -0700)]
Add a memory barrier.
Looks like an appropriate place for one.
Elliott Hughes [Wed, 14 Oct 2009 22:40:27 +0000 (15:40 -0700)]
Fix icu4jni Resources ("Locale") to not expose its internals.
We shouldn't expose internal arrays without copying.
Bug:
2102273
Jean-Baptiste Queru [Wed, 14 Oct 2009 23:12:50 +0000 (16:12 -0700)]
Jean-Baptiste Queru [Wed, 14 Oct 2009 23:02:09 +0000 (16:02 -0700)]
merge from open-source master
Elliott Hughes [Wed, 14 Oct 2009 19:12:11 +0000 (12:12 -0700)]
Fix build.
Add missing files from https://android-git.corp.google.com/g/29998.
Android (Google) Code Review [Wed, 14 Oct 2009 18:42:05 +0000 (14:42 -0400)]
Merge change Ic8d6b3cb
* changes:
Fix Constructor and Method to not expose their internals.
Android (Google) Code Review [Wed, 14 Oct 2009 17:48:59 +0000 (13:48 -0400)]
Merge change Ia0e7b60d
* changes:
Remove incorrect definition of nested local variables.
Android (Google) Code Review [Wed, 14 Oct 2009 17:12:35 +0000 (13:12 -0400)]
Merge change I0e52b194
* changes:
Bug fixing for NumberFormat and BigDecimal.
Elliott Hughes [Wed, 14 Oct 2009 17:07:42 +0000 (10:07 -0700)]
Fix build.
Work around apicheck bug.
Android (Google) Code Review [Wed, 14 Oct 2009 15:44:10 +0000 (11:44 -0400)]
Merge change I3a0b1f8c
* changes:
Update libcore/security to Harmony r823222.
Android (Google) Code Review [Wed, 14 Oct 2009 14:23:05 +0000 (10:23 -0400)]
Merge change Ic89dfdd8
* changes:
Bump "public" version from 1.1.0 to 1.2.0.
Android (Google) Code Review [Wed, 14 Oct 2009 14:22:50 +0000 (10:22 -0400)]
Merge change I0d6fff2d
* changes:
Avoid JDWP hang on nested thread suspension.
Android (Google) Code Review [Wed, 14 Oct 2009 07:42:03 +0000 (03:42 -0400)]
Merge change I9297389b
* changes:
Udating luni to Harmony r823222.
Ben Cheng [Wed, 14 Oct 2009 06:09:01 +0000 (23:09 -0700)]
Remove incorrect definition of nested local variables.
Elliott Hughes [Sat, 10 Oct 2009 00:21:46 +0000 (17:21 -0700)]
Update libcore/security to Harmony r823222.
Squashed commit of the following:
commit
e3083dde77b71fa817c8a52d9edafcb6325cfc25
Author: Elliott Hughes <enh@google.com>
Date: Fri Oct 9 13:10:11 2009 -0700
security_dalvik
commit
0fc0101e5dbfb3e3044702579ab8087a4e07984a
Author: Elliott Hughes <enh@google.com>
Date: Fri Oct 9 13:09:48 2009 -0700
security_527399
Elliott Hughes [Wed, 14 Oct 2009 01:18:21 +0000 (18:18 -0700)]
Fix Constructor and Method to not expose their internals.
We shouldn't expose internal arrays without copying. Behavior confirmed
by testing against RI.
Also connect up the dalvik ThreadsTest test that had fallen by the wayside.
Bug:
2102273
Andy McFadden [Tue, 13 Oct 2009 23:19:22 +0000 (16:19 -0700)]
Bump "public" version from 1.1.0 to 1.2.0.
Also, send correct version in JDWP VirtualMachine.Version packet.
Andy McFadden [Tue, 13 Oct 2009 23:04:31 +0000 (16:04 -0700)]
Avoid JDWP hang on nested thread suspension.
With jdb, you can suspend a thread multiple times. If you try to
execute a method -- which requires resuming a thread that has been
stopped at a breakpoint -- the VM currently only does a single "resume",
which means the thread is still suspended, and the JDWP thread hangs
waiting for it.
This adds a check to prevent the hang.
For bug
2183735.
Android (Google) Code Review [Tue, 13 Oct 2009 20:45:17 +0000 (16:45 -0400)]
Merge change Ied79ff0c
* changes:
Accept JitOff as a legal state in the debug interpreter when JIT is configured.
Ben Cheng [Tue, 13 Oct 2009 20:26:40 +0000 (13:26 -0700)]
Accept JitOff as a legal state in the debug interpreter when JIT is configured.
Andy McFadden [Tue, 13 Oct 2009 20:06:03 +0000 (13:06 -0700)]
Add JDWP ReferenceType.ClassObject handler.
For bug
2157236.
Android (Google) Code Review [Tue, 13 Oct 2009 19:24:25 +0000 (15:24 -0400)]
Merge change I60282050
* changes:
Add implementation of JDWP ClassType.NewInstance
Brett Chabot [Tue, 13 Oct 2009 18:57:48 +0000 (11:57 -0700)]
am
fef7556f: am
3238cc2a: am
32f89821: Merge change 26044 into donut-gms
Merge commit '
fef7556f058d0d17b30180c03387558bc59d3105'
* commit '
fef7556f058d0d17b30180c03387558bc59d3105':
Remove tests.api.java.io.FileTest#test_delete as known failure.
Brett Chabot [Tue, 13 Oct 2009 18:57:43 +0000 (11:57 -0700)]
am
4ebfaec4: am
98f0612b: am
c4d33d9d: Fix ClassLoaderTest to work on DEXPREOPT builds.
Merge commit '
4ebfaec453ae79e3ac1d7ff30cbc9f2d3beef2d1'
* commit '
4ebfaec453ae79e3ac1d7ff30cbc9f2d3beef2d1':
Fix ClassLoaderTest to work on DEXPREOPT builds.
Andy McFadden [Fri, 2 Oct 2009 22:56:26 +0000 (15:56 -0700)]
Add implementation of JDWP ClassType.NewInstance
Add a handler for the ClassType.NewInstance request, and some bits of
plumbing to go with it.
For bug
2157236.
Android (Google) Code Review [Mon, 12 Oct 2009 21:51:09 +0000 (17:51 -0400)]
Merge change I8f61592d
* changes:
Set the debug interpreter entry point properly on the self-verification path.
Jesse Wilson [Mon, 12 Oct 2009 21:07:16 +0000 (14:07 -0700)]
Bug fixing for NumberFormat and BigDecimal.
1. Fixed the bug that DecimalFormat does not handle multiplier.
2. Fixed the bug that DecimalFormat does not handle precision.
This is a copy of the original Eclair change,
https://android-git.corp.google.com/g/26297
Bug:
1897917.
Android (Google) Code Review [Mon, 12 Oct 2009 21:17:00 +0000 (17:17 -0400)]
Merge change I6618182f
* changes:
Fix CoreTestRunner to not run filtered-out tests.
Ben Cheng [Mon, 12 Oct 2009 20:46:55 +0000 (13:46 -0700)]
Set the debug interpreter entry point properly on the self-verification path.
Also fix the encoding for SFP/DFP register names to make self-verification
happy on FP benchmarks.
Elliott Hughes [Mon, 12 Oct 2009 21:08:50 +0000 (14:08 -0700)]
Fix CoreTestRunner to not run filtered-out tests.
https://android-git.corp.google.com/g/29284 broke test filtering by accidentally
passing the unfiltered test suite to super.doRun.
Android (Google) Code Review [Mon, 12 Oct 2009 20:54:08 +0000 (16:54 -0400)]
Merge change I1acdca65
* changes:
Fix memory corruption.
Android (Google) Code Review [Mon, 12 Oct 2009 20:43:15 +0000 (16:43 -0400)]
Merge change Iff8a3e91
* changes:
Adding timeouts to HttpsURLConnectionTest.
Jesse Wilson [Mon, 12 Oct 2009 19:58:01 +0000 (12:58 -0700)]
Adding timeouts to HttpsURLConnectionTest.
See bug http://b/issue?id=
2180571
Jesse Wilson [Mon, 12 Oct 2009 19:31:09 +0000 (12:31 -0700)]
Fix memory corruption.
Lorenzo Colitti [Mon, 12 Oct 2009 18:35:56 +0000 (11:35 -0700)]
am
e652b123: Make sure res is NULL if getaddrinfo fails.
Merge commit '
e652b123d2d65d40e5f51c0145cc453ea88631dc'
* commit '
e652b123d2d65d40e5f51c0145cc453ea88631dc':
Make sure res is NULL if getaddrinfo fails.
Jesse Wilson [Sat, 10 Oct 2009 04:53:23 +0000 (21:53 -0700)]
Adding a timeout for standard out as well as standard error.
Jesse Wilson [Fri, 9 Oct 2009 22:26:15 +0000 (15:26 -0700)]
Udating luni to Harmony r823222.
Highlights:
- InputStream.skip concurrency issue
- "better" messages in bound exceptions for streams and arrays
- prefer fewer writes to underlying streams (using byte[] buffers)
- Rename subclasses to not reuse names from their superclasses
- PlatformAddressFactory.allocMap bugfix
Plus some spelling fixes, style fixes, serial version UIDs and other
boilerplate improvements.
Android (Google) Code Review [Sat, 10 Oct 2009 01:21:46 +0000 (21:21 -0400)]
Merge change I164613f2
* changes:
Rewrite Support_Exec to support timeouts on waiting processes.
Jesse Wilson [Sat, 10 Oct 2009 00:41:52 +0000 (17:41 -0700)]
Rewrite Support_Exec to support timeouts on waiting processes.
Also rewriting SupportExec to use ProcessBuilder rather
than Runtime.exec(). Changed callers to use the ProcessBuilder
directly rather than calling-through chained methods.
Android (Google) Code Review [Fri, 9 Oct 2009 23:51:32 +0000 (19:51 -0400)]
Merge change Ic98d470a
* changes:
Remove the intermediate representation in getNetworkInterfaces.
Android (Google) Code Review [Fri, 9 Oct 2009 22:47:36 +0000 (18:47 -0400)]
Merge change I6239d93b
* changes:
Fix the docs for the no-arg Random() constructor to better reflect reality, and make the constructors more resilient with respect to subclassing by using System.identityHashCode() instead of Object.hashCode(), and also by not calling overridable methods.
Dan Bornstein [Fri, 9 Oct 2009 20:09:34 +0000 (13:09 -0700)]
Fix the docs for the no-arg Random() constructor to better reflect reality,
and make the constructors more resilient with respect to subclassing by
using System.identityHashCode() instead of Object.hashCode(), and also by
not calling overridable methods.
Change-Id: I6239d93bb46876ef1c4a5e155a6dc1ac6fab4eae
Android (Google) Code Review [Fri, 9 Oct 2009 20:27:42 +0000 (16:27 -0400)]
Merge change I0e98511f
* changes:
Do not initialize the JIT if it is not the designated execution mode.
Android (Google) Code Review [Fri, 9 Oct 2009 20:16:49 +0000 (16:16 -0400)]
Merge change I98acebf9
* changes:
Disable SMALL_BUFFERS and CUTTHROUGH, as SSLSession test fails with these flags.
Ben Cheng [Fri, 9 Oct 2009 18:55:30 +0000 (11:55 -0700)]
Do not initialize the JIT if it is not the designated execution mode.
Dan Bornstein [Thu, 8 Oct 2009 00:33:46 +0000 (17:33 -0700)]
Minor tweak for compatibility with BSD: Use MAP_ANON instead of MAP_ANONYMOUS.
The former is deprecated on Linux, but it is equivalent, and
MAP_ANONYMOUS isn't valid at all on BSD. (The alternative for BSD
compatibility is to use #ifdefs, but that seems gratuitously
heavyweight to me.)
Change-Id: I9c0b2cc78c4d7edc633487d5b0dde5b2f928247e
Android (Google) Code Review [Fri, 9 Oct 2009 16:49:15 +0000 (12:49 -0400)]
Merge change I5ccdf0be
* changes:
Fix for "Compiler thread shutdown should switch out of VMWAIT"
Nagendra Modadugu [Fri, 9 Oct 2009 01:34:48 +0000 (18:34 -0700)]
Disable SMALL_BUFFERS and CUTTHROUGH, as SSLSession test fails with these flags.
Elliott Hughes [Thu, 8 Oct 2009 23:56:37 +0000 (16:56 -0700)]
Squashed commit of the following:
commit
07d78447c89a11265bf909ab6bcc315c1a784281
Author: Elliott Hughes <enh@google.com>
Date: Thu Oct 8 16:38:26 2009 -0700
text_dalvik
commit
c390506ce060c705b6c1b04fb1e737617de1bd8a
Author: Elliott Hughes <enh@google.com>
Date: Thu Oct 8 16:38:22 2009 -0700
text_802921
Ben Cheng [Thu, 8 Oct 2009 23:09:49 +0000 (16:09 -0700)]
Fix for "Compiler thread shutdown should switch out of VMWAIT"
Jesse Wilson [Thu, 8 Oct 2009 07:25:33 +0000 (00:25 -0700)]
Tools to push code back upstream.
Android (Google) Code Review [Thu, 8 Oct 2009 18:29:37 +0000 (14:29 -0400)]
Merge change I685130ae
* changes:
JNI Delete* and Release* _are_ allowed while an exception is pending.