diff options
author | Tom Tromey <tromey@redhat.com> | 2001-07-30 20:24:18 +0000 |
---|---|---|
committer | Tom Tromey <tromey@gcc.gnu.org> | 2001-07-30 20:24:18 +0000 |
commit | 3d5aea83669398c151371796f2b84cbb0f52727c (patch) | |
tree | 4008d0e99166835f26dd98f0224f49ecfaeb2e89 /libjava/java | |
parent | a08b260482d8972aaaa3eb2a0175f9cc175dbad9 (diff) | |
download | gcc-3d5aea83669398c151371796f2b84cbb0f52727c.zip gcc-3d5aea83669398c151371796f2b84cbb0f52727c.tar.gz gcc-3d5aea83669398c151371796f2b84cbb0f52727c.tar.bz2 |
natIconv.cc (done): New methods.
2001-07-30 Tom Tromey <tromey@redhat.com>
Corey Minyard <minyard@acm.org>
* gnu/gcj/convert/natIconv.cc (done): New methods.
* gnu/gcj/convert/Output_iconv.java (done): New method.
* gnu/gcj/convert/Input_iconv.java (done): New method.
* gnu/gcj/convert/UnicodeToBytes.java (defaultEncodingClass):
Removed.
(getDefaultEncodingClass): Removed.
(getDefaultEncoder): Use getEncoder.
(done): New method.
(defaultEncoding, CACHE_SIZE, encoderCache, currCachePos): New
static fields.
* gnu/gcj/convert/BytesToUnicode.java (defaultDecodingClass):
Removed.
(defaultEncoding, CACHE_SIZE, decoderCache, currCachePos): New
static fields.
(getDefaultDecodingClass): Removed.
(getDefaultDecoder): Use getDecoder.
(getDecoder): Look up decoder in cache.
(done): New method.
* java/lang/natString.cc (init): Call `done' on converter.
(getBytes): Likewise.
Co-Authored-By: Corey Minyard <minyard@acm.org>
From-SVN: r44484
Diffstat (limited to 'libjava/java')
-rw-r--r-- | libjava/java/lang/natString.cc | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libjava/java/lang/natString.cc b/libjava/java/lang/natString.cc index 82d5d0c..ee31ba5 100644 --- a/libjava/java/lang/natString.cc +++ b/libjava/java/lang/natString.cc @@ -523,6 +523,7 @@ java::lang::String::init (jbyteArray bytes, jint offset, jint count, avail -= done; } } + converter->done (); this->data = array; this->boffset = (char *) elements (array) - (char *) array; this->count = outpos; @@ -604,6 +605,7 @@ java::lang::String::getBytes (jstring enc) todo -= converted; } } + converter->done (); if (bufpos == buflen) return buffer; jbyteArray result = JvNewByteArray(bufpos); |