text stringlengths 0 234 |
|---|
cp_length_2_trees : |
constant Length_array (0 .. 63) := |
(2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, |
18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, |
35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, |
52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65); |
cp_length_3_trees : |
constant Length_array (0 .. 63) := |
(3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, |
19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, |
36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, |
53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66); |
cp_dist_4KB : |
constant Length_array (0 .. 63) := |
(1, 65, 129, 193, 257, 321, 385, 449, 513, 577, 641, 705, |
769, 833, 897, 961, 1025, 1089, 1153, 1217, 1281, 1345, 1409, 1473, |
1537, 1601, 1665, 1729, 1793, 1857, 1921, 1985, 2049, 2113, 2177, |
2241, 2305, 2369, 2433, 2497, 2561, 2625, 2689, 2753, 2817, 2881, |
2945, 3009, 3073, 3137, 3201, 3265, 3329, 3393, 3457, 3521, 3585, |
3649, 3713, 3777, 3841, 3905, 3969, 4033); |
cp_dist_8KB : |
constant Length_array (0 .. 63) := |
(1, 129, 257, 385, 513, 641, 769, 897, 1025, 1153, 1281, |
1409, 1537, 1665, 1793, 1921, 2049, 2177, 2305, 2433, 2561, 2689, |
2817, 2945, 3073, 3201, 3329, 3457, 3585, 3713, 3841, 3969, 4097, |
4225, 4353, 4481, 4609, 4737, 4865, 4993, 5121, 5249, 5377, 5505, |
5633, 5761, 5889, 6017, 6145, 6273, 6401, 6529, 6657, 6785, 6913, |
7041, 7169, 7297, 7425, 7553, 7681, 7809, 7937, 8065); |
extra : |
constant Length_array (0 .. 63) := (0 .. 62 => 0, 63 => 8); |
begin |
Bl := 7; |
if UnZ_Glob.compsize > 200000 then |
Bd := 8; |
else |
Bd := 7; |
end if; |
if literal_tree then |
Bb := 9; |
Get_Tree (L); |
begin |
HufT_build (L, 256, empty, empty, Tb, Bb, huft_incomplete); |
if huft_incomplete then |
HufT_free (Tb); |
raise Zip.Zip_file_Error; |
end if; |
exception |
when others => |
raise Zip.Zip_file_Error; |
Function Definition: procedure Copy_stored is |
Function Body: size : constant UnZip.File_size_type := UnZ_Glob.compsize; |
read_in, absorbed : UnZip.File_size_type; |
begin |
absorbed := 0; |
if UnZ_IO.Decryption.Get_mode then |
absorbed := 12; |
end if; |
while absorbed < size loop |
read_in := size - absorbed; |
if read_in > wsize then |
read_in := wsize; |
end if; |
begin |
for I in 0 .. read_in - 1 loop |
UnZ_IO.Read_raw_byte (UnZ_Glob.slide (Natural (I))); |
end loop; |
exception |
when others => |
raise UnZip.Read_Error; |
Function Definition: procedure Inflate_stored_block is -- Actually, nothing to inflate |
Function Body: N : Integer; |
begin |
if full_trace then |
pragma Warnings (Off, "this code can never be executed and has been deleted"); |
Ada.Text_IO.Put_Line ("Begin Inflate_stored_block"); |
pragma Warnings (On, "this code can never be executed and has been deleted"); |
end if; |
UnZ_IO.Bit_buffer.Dump_to_byte_boundary; |
-- Get the block length and its complement |
N := UnZ_IO.Bit_buffer.Read_and_dump (16); |
if N /= Integer ( |
(not UnZ_IO.Bit_buffer.Read_and_dump_U32 (16)) |
and 16#ffff#) |
then |
raise Zip.Zip_file_Error; |
end if; |
while N > 0 and then not UnZ_Glob.Zip_EOF loop |
-- Read and output the non - compressed data |
N := N - 1; |
UnZ_Glob.slide (UnZ_Glob.slide_index) := |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.