Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterInputStreamTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterInputStreamTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterInputStreamTest.java (working copy)
@@ -82,7 +82,7 @@
InflaterInputStream inflatIP = new InflaterInputStream(infile,
inflate);
- inflatIP.read(byteArray, 0, 5);// ony suppose to read in 5 bytes
+ inflatIP.read(byteArray, 0, 5);// only suppose to read in 5 bytes
inflatIP.close();
}
@@ -150,7 +150,7 @@
for (int j = 0; j < orgBuffer.length; j++) {
assertTrue(
- "orginal compressed data did not equal decompressed data",
+ "original compressed data did not equal decompressed data",
buffer[j] == orgBuffer[j]);
}
}
@@ -248,10 +248,10 @@
skip = inflatIP2.skip(Integer.MAX_VALUE);
// System.out.println(skip);
- assertEquals("method skip() returned wrong number of bytes skiped",
+ assertEquals("method skip() returned wrong number of bytes skipped",
5, skip);
- // test for skiping of 2 bytes
+ // test for skipping of 2 bytes
InputStream infile3 = Support_Resources
.getStream("hyts_constru(OD).txt");
InflaterInputStream inflatIP3 = new InflaterInputStream(infile3);
@@ -268,7 +268,7 @@
for (int j = 2; j < orgBuffer.length; j++) {
assertTrue(
- "orginal compressed data did not equal decompressed data",
+ "original compressed data did not equal decompressed data",
buffer[j - 2] == orgBuffer[j]);
}
}
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/InflaterTest.java (working copy)
@@ -398,13 +398,13 @@
inflate.inflate(outPutInf);
}
for (int i = 0; i < byteArray.length; i++) {
- assertEquals("the output array from inflate should contain 0 because the header of inflate and deflate did not match, but this faled",
+ assertEquals("the output array from inflate should contain 0 because the header of inflate and deflate did not match, but this failed",
0, outPutBuff1[i]);
}
} catch (DataFormatException e) {
r = 1;
}
- assertEquals("Error: exception should be thrown becuase of header inconsistancy",
+ assertEquals("Error: exception should be thrown because of header inconsistency",
1, r);
}
@@ -535,14 +535,14 @@
public void test_setDictionary$B() {
//FIXME This test doesn't pass in Harmony classlib or Sun 5.0_7 RI
/*
- // test method of java.tuil.zip.inflater.setDictionary(byte)
+ // test method of java.util.zip.inflater.setDictionary(byte)
byte dictionaryArray[] = { 'e', 'r', 't', 'a', 'b', 2, 3 };
byte byteArray[] = { 4, 5, 3, 2, 'a', 'b', 6, 7, 8, 9, 0, 's', '3',
'w', 'r' };
byte outPutInf[] = new byte[100];
- // trying to inflate without seting a dictionary
+ // trying to inflate without setting a dictionary
Inflater inflateWO = new Inflater();
byte outPutInf2[] = new byte[100];
@@ -607,7 +607,7 @@
Inflater inflate = new Inflater();
inflate.setInput(byteArray, offSet, length);
assertTrue(
- "setInputBII did not deliever the right number of bytes to the input buffer",
+ "setInputBII did not deliver the right number of bytes to the input buffer",
inflate.getRemaining() == length);
// boundary check
inflate.reset();
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/GZIPInputStreamTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/GZIPInputStreamTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/GZIPInputStreamTest.java (working copy)
@@ -122,7 +122,7 @@
2074883667L, inGZIP.getChecksum().getValue());
for (int i = 0; i < orgBuf.length; i++) {
assertTrue(
- "the decompressed data does not equal the orginal data decompressed",
+ "the decompressed data does not equal the original data decompressed",
orgBuf[i] == outBuf[i]);
// System.out.println(orgBuf[i] + " " + outBuf[i]);
}
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/CheckedOutputStreamTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/CheckedOutputStreamTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/CheckedOutputStreamTest.java (working copy)
@@ -42,7 +42,7 @@
fail("Unable to find file");
} catch (SecurityException e) {
fail(
- "file cannot be opend for writing due to security reasons");
+ "file cannot be opened for writing due to security reasons");
}
}
@@ -74,7 +74,7 @@
fail("Unable to find file");
} catch (SecurityException e) {
fail(
- "file cannot be opend for writing due to security reasons");
+ "file cannot be opened for writing due to security reasons");
}
}
@@ -128,7 +128,7 @@
fail("Unable to find file");
} catch (SecurityException e) {
fail(
- "file cannot be opend for writing due to security reasons");
+ "file cannot be opened for writing due to security reasons");
} catch (IndexOutOfBoundsException e) {
fail("Index for write is out of bounds");
}
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterOutputStreamTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterOutputStreamTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterOutputStreamTest.java (working copy)
@@ -74,7 +74,7 @@
defl = new Deflater();
dos = new MyDeflaterOutputStream(fos, defl);
- // Test to see if DflaterOutputStream was created with the correct
+ // Test to see if DeflaterOutputStream was created with the correct
// buffer.
assertEquals("Incorrect Buffer Size",
512, dos.getProtectedBuf().length);
@@ -101,7 +101,7 @@
FileOutputStream fos = new FileOutputStream(f1);
MyDeflaterOutputStream dos = new MyDeflaterOutputStream(fos);
- // Test to see if DflaterOutputStream was created with the correct
+ // Test to see if DeflaterOutputStream was created with the correct
// buffer.
assertEquals("Incorrect Buffer Size",
512, dos.getProtectedBuf().length);
@@ -157,7 +157,7 @@
} catch (IllegalArgumentException e) {
}
- // Test to see if DflaterOutputStream was created with the correct
+ // Test to see if DeflaterOutputStream was created with the correct
// buffer.
dos = new MyDeflaterOutputStream(fos, defl, buf);
assertEquals("Incorrect Buffer Size",
@@ -430,7 +430,7 @@
f2.delete();
} catch (SecurityException e) {
- fail("Unexpectd SecurityException during test");
+ fail("Unexpected SecurityException during test");
} catch (IOException e) {
fail("Unexpected IOException during test");
}
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipEntryTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipEntryTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/ZipEntryTest.java (working copy)
@@ -479,7 +479,7 @@
java.io.File f = new java.io.File(tempFileName);
f.delete();
} catch (java.io.IOException e) {
- System.out.println("Exception durnig tearDown");
+ System.out.println("Exception during tearDown");
}
}
Index: src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/zip/DeflaterTest.java (working copy)
@@ -359,7 +359,7 @@
defl.deflate(outPutBuf);
}
assertTrue(
- "The number of input byte sent to setInputBII() did not corrsepond with getTotalIn",
+ "The number of input byte sent to setInputBII() did not correspond with getTotalIn",
defl.getTotalIn() == length);
defl.end();
}
@@ -979,7 +979,7 @@
"Final decompressed data does not equal the original data",
byteArray[i] == outPutInf[i]);
}
- assertEquals("final decompressed data contained more bytes than original - construcotrIZ",
+ assertEquals("final decompressed data contained more bytes than original - constructorIZ",
0, outPutInf[byteArray.length]);
infl.end();
Index: src/test/java/org/apache/harmony/archive/tests/java/util/jar/JarFileTest.java
===================================================================
--- src/test/java/org/apache/harmony/archive/tests/java/util/jar/JarFileTest.java (revision 485183)
+++ src/test/java/org/apache/harmony/archive/tests/java/util/jar/JarFileTest.java (working copy)
@@ -470,7 +470,7 @@
while (in.available() > 0) {
in.read(buffer);
}
- fail("should throw Security Excetpion");
+ fail("should throw Security Exception");
} catch (SecurityException e) {
// desired
}
@@ -492,7 +492,7 @@
ZipEntry zipEntry = entries.nextElement();
try {
jarFile.getInputStream(zipEntry);
- fail("should throw Security Excetpion");
+ fail("should throw Security Exception");
} catch (SecurityException e) {
// desired
}
@@ -515,7 +515,7 @@
ZipEntry zipEntry = entries.nextElement();
try {
jarFile.getInputStream(zipEntry);
- fail("should throw Security Excetpion");
+ fail("should throw Security Exception");
} catch (SecurityException e) {
// desired
}
@@ -524,7 +524,7 @@
/*
* If the content of the .SA file is modified, no matter what it resides,
- * JarFile.getInfputStream of any JarEntry will throw Security Exception.
+ * JarFile.getInputStream of any JarEntry will throw Security Exception.
*/
public void test_JarFile_Modified_SF_EntryAttributes() throws IOException {
String modifiedJarName = "Modified_SF_EntryAttributes.jar";
@@ -536,7 +536,7 @@
ZipEntry zipEntry = entries.nextElement();
try {
jarFile.getInputStream(zipEntry);
- fail("should throw Security Excetpion");
+ fail("should throw Security Exception");
} catch (SecurityException e) {
// desired
}
Index: src/main/java/java/util/zip/ZipOutputStream.java
===================================================================
--- src/main/java/java/util/zip/ZipOutputStream.java (revision 485183)
+++ src/main/java/java/util/zip/ZipOutputStream.java (working copy)
@@ -26,7 +26,7 @@
import org.apache.harmony.archive.internal.nls.Messages;
/**
- * ZipOuputStream is used to write ZipEntries to the underlying stream. Output
+ * ZipOutputStream is used to write ZipEntries to the underlying stream. Output
* from ZipOutputStream conforms to the ZipFile file format.
*
* @see ZipInputStream
Index: src/main/java/java/util/zip/InflaterInputStream.java
===================================================================
--- src/main/java/java/util/zip/InflaterInputStream.java (revision 485183)
+++ src/main/java/java/util/zip/InflaterInputStream.java (working copy)
@@ -26,7 +26,7 @@
import org.apache.harmony.archive.internal.nls.Messages;
/**
- * InflaterOuputStream read data which has been compressed using the DEFLATE
+ * InflaterOutputStream read data which has been compressed using the DEFLATE
* compression method.
*
* @see Inflater
Index: src/main/java/java/util/zip/Inflater.java
===================================================================
--- src/main/java/java/util/zip/Inflater.java (revision 485183)
+++ src/main/java/java/util/zip/Inflater.java (working copy)
@@ -242,7 +242,7 @@
/**
* Sets the preset dictionary to be used for inflation to buf.
- * needsDictioanry() can be called to determine whether the current input
+ * needsDictionary() can be called to determine whether the current input
* was deflated using a preset dictionary.
*
* @param buf
Index: src/main/java/java/util/zip/CRC32.java
===================================================================
--- src/main/java/java/util/zip/CRC32.java (revision 485183)
+++ src/main/java/java/util/zip/CRC32.java (working copy)
@@ -68,7 +68,7 @@
* @param buf
* Buffer to update Checksum
* @param off
- * Offest in buf to obtain data from
+ * Offset in buf to obtain data from
* @param nbytes
* Number of bytes to read from buf
*/
Index: src/main/java/java/util/zip/Adler32.java
===================================================================
--- src/main/java/java/util/zip/Adler32.java (revision 485183)
+++ src/main/java/java/util/zip/Adler32.java (working copy)
@@ -66,9 +66,9 @@
* offset and using nbytes of data.
*
* @param buf
- * bufffer to obtain dat from
+ * buffer to obtain dat from
* @param off
- * offset i buf to conpy from
+ * offset i buf to copy from
* @param nbytes
* number of bytes from buf to use
*/
Index: src/main/java/java/util/jar/Pack200.java
===================================================================
--- src/main/java/java/util/jar/Pack200.java (revision 485183)
+++ src/main/java/java/util/jar/Pack200.java (working copy)
@@ -45,7 +45,7 @@
/**
* The method first read from system property for the classname of a Packer,
- * if such property exsists,the class shall be initialized; or the default
+ * if such property exists, the class shall be initialized; or the default
* Packer will be returned
*
* @return a instance of Packer
@@ -72,7 +72,7 @@
/**
* The method first read from system property for the classname of a
- * Unpacker, if such property exsists,the class shall be initialized; or the
+ * Unpacker, if such property exists, the class shall be initialized; or the
* default Unpacker will be returned
*
* @return a instance of Unpacker
Index: src/main/java/java/util/jar/JarOutputStream.java
===================================================================
--- src/main/java/java/util/jar/JarOutputStream.java (revision 485183)
+++ src/main/java/java/util/jar/JarOutputStream.java (working copy)
@@ -30,7 +30,7 @@
private Manifest manifest;
/**
- * Contructs a new JarOuputStream using os as the underlying stream.
+ * Constructs a new JarOutputStream using os as the underlying stream.
* Manifest information for the JarFile to be written is obtained from the
* parameter Manifest, mf.
*
@@ -54,7 +54,7 @@
}
/**
- * Contructs a new JarOuputStream using os as the underlying stream.
+ * Constructs a new JarOutputStream using os as the underlying stream.
*
* @param os
* The OutputStream to write to
Index: src/main/java/java/util/jar/JarException.java
===================================================================
--- src/main/java/java/util/jar/JarException.java (revision 485183)
+++ src/main/java/java/util/jar/JarException.java (working copy)
@@ -20,7 +20,7 @@
import java.util.zip.ZipException;
/**
- * This runtime exception is thrown when a problem occurrs while reading a JAR
+ * This runtime exception is thrown when a problem occurs while reading a JAR
* file.
*/
public class JarException extends ZipException {
Index: src/main/java/java/util/jar/JarEntry.java
===================================================================
--- src/main/java/java/util/jar/JarEntry.java (revision 485183)
+++ src/main/java/java/util/jar/JarEntry.java (working copy)
@@ -150,7 +150,7 @@
for (Certificate element : certs) {
if (!(element instanceof X509Certificate)) {
- // Only X509CErtificate-s are taken into account - see API spec.
+ // Only X509Certificate-s are taken into account - see API spec.
continue;
}
X509Certificate x509 = (X509Certificate) element;
Index: src/main/java/org/apache/harmony/archive/internal/pack200/AttributeLayoutMap.java
===================================================================
--- src/main/java/org/apache/harmony/archive/internal/pack200/AttributeLayoutMap.java (revision 485183)
+++ src/main/java/org/apache/harmony/archive/internal/pack200/AttributeLayoutMap.java (working copy)
@@ -24,7 +24,7 @@
/**
* Stores a mapping from attribute names to their corresponding layout types.
* Note that names of attribute layouts and their formats are not
- * internationalised, and should not be translated.
+ * internationalized, and should not be translated.
*/
public class AttributeLayoutMap {
// create a whole bunch of AttributeLayouts here
Index: src/main/java/org/apache/harmony/archive/internal/pack200/Segment.java
===================================================================
--- src/main/java/org/apache/harmony/archive/internal/pack200/Segment.java (revision 485183)
+++ src/main/java/org/apache/harmony/archive/internal/pack200/Segment.java (working copy)
@@ -808,7 +808,7 @@
}
}
if (codeBands > 0)
- throw new Error("Can't handle non-abstract, non-native methods/initialisers at the moment (found " + codeBands + " code bands)");
+ throw new Error("Can't handle non-abstract, non-native methods/initializers at the moment (found " + codeBands + " code bands)");
debug("unimplemented code_headers");
debug("unimplemented code_max_stack");
debug("unimplemented code_max_na_locals");
@@ -995,7 +995,7 @@
* public static void main(String args[]) has a form of
* [L(V) and a classes array of
* [java.lang.String]. The {@link #cpSignature} is a string
- * represenation identical to the bytecode equivalent
+ * representation identical to the bytecode equivalent
* [Ljava/lang/String;(V) TODO Check that the form is as
* above and update other types e.g. J
*
@@ -1092,7 +1092,7 @@
last = (int) Codec.DELTA5.decode(in, last);
bigSuffixData[i] = new char[(int) last];
}
- // initialise big suffix data
+ // initialize big suffix data
for (int i = 0; i < bigSuffix; i++) {
char[] singleBigSuffixData = bigSuffixData[i];
last = 0;
@@ -1514,7 +1514,7 @@
int size = (int) fileSize[i];
// TODO This buggers up if file_size > 2^32. Probably an array is
// not the right choice, and
- // we should just serialise the bugger here?
+ // we should just serialize the bugger here?
fileBits[i] = new byte[size];
for (int j = 0; j < size; j++) {
fileBits[i][j] = (byte) Codec.BYTE1.decode(in);
Index: src/main/java/org/apache/harmony/archive/internal/pack200/PopulationCodec.java
===================================================================
--- src/main/java/org/apache/harmony/archive/internal/pack200/PopulationCodec.java (revision 485183)
+++ src/main/java/org/apache/harmony/archive/internal/pack200/PopulationCodec.java (working copy)
@@ -56,7 +56,7 @@
public long[] decode(int n, InputStream in) throws IOException, Pack200Exception {
long favoured[] =new long[n]; // there must be <= n values, but probably a lot less
long result[];
- // read table of favourites first
+ // read table of favorites first
long smallest = Long.MAX_VALUE;
long last = 0;
long value = 0; // TODO Are these sensible starting points?
@@ -90,9 +90,9 @@
throw new Pack200Exception("Cannot calculate token codec from " + k + " and " + l);
}
}
- // read favourites
+ // read favorites
result = tokenCodec.decode(n, in);
- // read unfavourites
+ // read unfavorites
last = 0;
for(int i=0;i
* H
* The radix of the integer. Values are defined as a sequence of values,
- * where value n is multipled by H^n.
+ * where value n is multiplied by H^n.
* So the number 1234 may be represented as the sequence 4 3 2 1 with a radix
* (H) of 10. Note that other permutations are also possible; 43 2 1 will also
* encode 1234. The co-parameter L is defined as 256-H. This is important
@@ -63,7 +63,7 @@
* codec is a non-delta encoding, then the value is ignored if passed. If the
* codec is a delta encoding, it is a run-time error to call the value without
* the extra parameter, and the previous value should be returned. (It was
- * designed this way to support multi-threaded access without requring a new
+ * designed this way to support multi-threaded access without requiring a new
* instance of the Codec to be cloned for each use.)
*
*
Index: src/main/java/org/apache/harmony/archive/internal/pack200/BHSDCodec.java
===================================================================
--- src/main/java/org/apache/harmony/archive/internal/pack200/BHSDCodec.java (revision 485183)
+++ src/main/java/org/apache/harmony/archive/internal/pack200/BHSDCodec.java (working copy)
@@ -201,14 +201,14 @@
/**
* Returns the largest value that this codec can represent.
*
- * @eturn the largest value that this codec can represent.
+ * @return the largest value that this codec can represent.
*/
public long largest() {
long result;
if (isDelta()) {
result = Long.MAX_VALUE;
} else {
- // TODO This can probably be optimised into a better mathematical statement
+ // TODO This can probably be optimized into a better mathematical statement
if (s == 0) {
result = cardinality() - 1;
} else if (s == 1) {
@@ -225,7 +225,7 @@
/**
* Returns the smallest value that this codec can represent.
*
- * @eturn the smallest value that this codec can represent.
+ * @return the smallest value that this codec can represent.
*/
public long smallest() {
long result;
Index: src/main/native/zip/shared/zipcache.c
===================================================================
--- src/main/native/zip/shared/zipcache.c (revision 485183)
+++ src/main/native/zip/shared/zipcache.c (working copy)
@@ -87,7 +87,7 @@
typedef struct HyZipCacheEntry
{
- HyZipCache info; /* publically visible part */
+ HyZipCache info; /* publicly visible part */
HaZipChunkHeader *currentChunk;
HaZipDirEntry *chunkActiveDir;
HaZipDirEntry root;
@@ -134,7 +134,7 @@
* @param[in] zipName the zip file name
* @param[in] zipNameLength
*
- * @return the new zip cache if one was succesfully created, NULL otherwise
+ * @return the new zip cache if one was successfully created, NULL otherwise
*
*/
@@ -756,7 +756,7 @@
*
* @return 0 on success
* @return -1 if all the directories have been returned already
- * @return the required size of nameBuf if nameBufSize is insuffient to hold the entire name (does not skip the element)
+ * @return the required size of nameBuf if nameBufSize is insufficient to hold the entire name (does not skip the element)
*
* @see zipCache_enumNew
*