186187188189190191192193194195196
throw new Exception("length incorrect"); for (int j = 0; j < length; j++) { byte b = (byte) (gen.nextInt() & 0x7F); if (file.readByte() != b) throw new Exception("contents incorrect"); } file.close(); }
375376377378379380381382383384385
throw new Exception("length incorrect"); for (int j = 0; j < length; j++) { byte b = (byte) (gen.nextInt() & 0x7F); if (file.readByte() != b) throw new Exception("contents incorrect"); } file.close(); } else {
193194195196197198199200201202203
throw new Exception("length incorrect"); for (int j = 0; j < length; j++) { byte b = (byte)(gen.nextInt() & 0x7F); if (file.readByte() != b) throw new Exception("contents incorrect"); } file.close(); }
184185186187188189190191192193194
371372373374375376377378379380381
190191192193194195196197198199200
189190191192193194195196197198199
8889909192939495969798
if (file.length() != length) throw new Exception("length incorrect"); for (int j = 0; j < length; j++) if (file.readByte() != b) throw new Exception("contents incorrect"); file.close(); }