Commit 651ba822 by Michael Koch Committed by Michael Koch

2004-07-17 Michael Koch <konqueror@gmx.de>

	* java/nio/ByteOrder.java
	(static): Removed. Not needed.
	Thanks to Patrick Reali for noticing.
	* java/nio/charset/CharsetDecoder.java
	(decode): Fix for classpath bug #9177: Reset state before flipping.

From-SVN: r84856
parent e3fe5b9c
2004-07-17 Michael Koch <konqueror@gmx.de> 2004-07-17 Michael Koch <konqueror@gmx.de>
* java/nio/ByteOrder.java
(static): Removed. Not needed.
Thanks to Patrick Reali for noticing.
* java/nio/charset/CharsetDecoder.java
(decode): Fix for classpath bug #9177: Reset state before flipping.
2004-07-17 Michael Koch <konqueror@gmx.de>
* java/security/Security.java: Fixed javadocs all over. * java/security/Security.java: Fixed javadocs all over.
2004-07-17 Michael Koch <konqueror@gmx.de> 2004-07-17 Michael Koch <konqueror@gmx.de>
......
...@@ -46,22 +46,13 @@ import gnu.classpath.Configuration; ...@@ -46,22 +46,13 @@ import gnu.classpath.Configuration;
*/ */
public final class ByteOrder public final class ByteOrder
{ {
public static final ByteOrder BIG_ENDIAN = new ByteOrder(); public static final ByteOrder BIG_ENDIAN = new ByteOrder();
public static final ByteOrder LITTLE_ENDIAN = new ByteOrder(); public static final ByteOrder LITTLE_ENDIAN = new ByteOrder();
static
{
// load the shared library needed for native methods.
if (Configuration.INIT_LOAD_LIBRARY)
{
System.loadLibrary ("javanio");
}
}
/** /**
* Returns the native byte order of the platform currently running. * Returns the native byte order of the platform currently running.
*/ */
public static ByteOrder nativeOrder () public static ByteOrder nativeOrder()
{ {
return (System.getProperty ("gnu.cpu.endian").equals("big") return (System.getProperty ("gnu.cpu.endian").equals("big")
? BIG_ENDIAN : LITTLE_ENDIAN); ? BIG_ENDIAN : LITTLE_ENDIAN);
...@@ -76,7 +67,7 @@ public final class ByteOrder ...@@ -76,7 +67,7 @@ public final class ByteOrder
} }
// This class can only be instantiated here. // This class can only be instantiated here.
private ByteOrder () private ByteOrder()
{ {
} }
} }
...@@ -129,6 +129,7 @@ public abstract class CharsetDecoder ...@@ -129,6 +129,7 @@ public abstract class CharsetDecoder
if (cr.isError ()) if (cr.isError ())
cr.throwException (); cr.throwException ();
reset();
out.flip (); out.flip ();
return out; return out;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment