You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
6
+
7
+
// Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
8
+
// Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
9
+
// Neither the name of ComponentAce nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
10
+
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
11
+
12
+
13
+
14
+
/*
15
+
Copyright (c) 2000,2001,2002,2003 ymnk, JCraft,Inc. All rights reserved.
16
+
17
+
Redistribution and use in source and binary forms, with or without
18
+
modification, are permitted provided that the following conditions are met:
19
+
20
+
1. Redistributions of source code must retain the above copyright notice,
21
+
this list of conditions and the following disclaimer.
22
+
23
+
2. Redistributions in binary form must reproduce the above copyright
24
+
notice, this list of conditions and the following disclaimer in
25
+
the documentation and/or other materials provided with the distribution.
26
+
27
+
3. The names of the authors may not be used to endorse or promote products
28
+
derived from this software without specific prior written permission.
29
+
30
+
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
31
+
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
32
+
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL JCRAFT,
33
+
INC. OR ANY CONTRIBUTORS TO THIS SOFTWARE BE LIABLE FOR ANY DIRECT, INDIRECT,
34
+
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
35
+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
36
+
OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
37
+
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
38
+
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
39
+
EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
40
+
*/
41
+
/*
42
+
* This program is based on zlib-1.1.3, so all credit should go authors
43
+
* Jean-loup Gailly(jloup@gzip.org) and Mark Adler(madler@alumni.caltech.edu)
44
+
* and contributors of zlib.
45
+
*/
46
+
usingSystem;
47
+
namespaceComponentAce.Compression.Libs.zlib
48
+
{
49
+
50
+
sealedclassAdler32
51
+
{
52
+
53
+
// largest prime smaller than 65536
54
+
privateconstintBASE=65521;
55
+
// NMAX is the largest n such that 255n(n+1)/2 + (n+1)(BASE-1) <= 2^32-1
0 commit comments