Commit fc90c25e authored by Dimitri van Heesch's avatar Dimitri van Heesch

Release-1.5.4

parent f57b7d97
# Doxyfile 1.4.3
# Doxyfile 1.5.2
#---------------------------------------------------------------------------
# Project related configuration options
#---------------------------------------------------------------------------
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = Doxygen
PROJECT_NUMBER =
OUTPUT_DIRECTORY = doxygen_docs
CREATE_SUBDIRS = NO
CREATE_SUBDIRS = YES
OUTPUT_LANGUAGE = English
USE_WINDOWS_ENCODING = NO
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF =
......@@ -19,15 +19,18 @@ STRIP_FROM_PATH =
STRIP_FROM_INC_PATH =
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = YES
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
DETAILS_AT_TOP = NO
INHERIT_DOCS = YES
DISTRIBUTE_GROUP_DOC = NO
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 8
ALIASES =
OPTIMIZE_OUTPUT_FOR_C = NO
OPTIMIZE_OUTPUT_JAVA = NO
BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
DISTRIBUTE_GROUP_DOC = NO
SUBGROUPING = YES
#---------------------------------------------------------------------------
# Build related configuration options
......@@ -72,6 +75,7 @@ WARN_LOGFILE =
# configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = src
INPUT_ENCODING = UTF-8
FILE_PATTERNS = *.h \
*.cpp
RECURSIVE = NO
......@@ -95,9 +99,11 @@ EXCLUDE = src/code.cpp \
src/pycode.cpp \
src/config.cpp \
src/pyscanner.cpp \
src/fortranscanner.cpp \
src/fortrancode.cpp
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXCLUDE_SYMBOLS =
EXAMPLE_PATH =
EXAMPLE_PATTERNS =
EXAMPLE_RECURSIVE = NO
......@@ -113,6 +119,7 @@ INLINE_SOURCES = NO
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = YES
REFERENCES_RELATION = YES
REFERENCES_LINK_SOURCE = YES
USE_HTAGS = NO
VERBATIM_HEADERS = YES
#---------------------------------------------------------------------------
......@@ -132,6 +139,7 @@ HTML_FOOTER =
HTML_STYLESHEET =
HTML_ALIGN_MEMBERS = YES
GENERATE_HTMLHELP = NO
HTML_DYNAMIC_SECTIONS = YES
CHM_FILE =
HHC_LOCATION =
GENERATE_CHI = NO
......@@ -144,7 +152,7 @@ TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
GENERATE_LATEX = NO
GENERATE_LATEX = YES
LATEX_OUTPUT =
LATEX_CMD_NAME = latex
MAKEINDEX_CMD_NAME = makeindex
......@@ -215,6 +223,7 @@ PERL_PATH = /usr/bin/perl
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
CLASS_DIAGRAMS = NO
MSCGEN_PATH =
HIDE_UNDOC_RELATIONS = YES
HAVE_DOT = YES
CLASS_GRAPH = YES
......@@ -225,13 +234,13 @@ TEMPLATE_RELATIONS = YES
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = NO
CALL_GRAPH = NO
CALLER_GRAPH = NO
GRAPHICAL_HIERARCHY = YES
DIRECTORY_GRAPH = YES
DOT_IMAGE_FORMAT = png
DOT_PATH =
DOTFILE_DIRS =
MAX_DOT_GRAPH_WIDTH = 1024
MAX_DOT_GRAPH_HEIGHT = 1024
DOT_GRAPH_MAX_NODES = 50
MAX_DOT_GRAPH_DEPTH = 0
DOT_TRANSPARENT = NO
DOT_MULTI_TARGETS = NO
......
DOXYGEN Version 1.5.3-20070925
DOXYGEN Version 1.5.4
Please read the installation section of the manual
(http://www.doxygen.org/install.html) for instructions.
--------
Dimitri van Heesch (25 September 2007)
Dimitri van Heesch (26 October 2007)
DOXYGEN Version 1.5.3_20070925
DOXYGEN Version 1.5.4
Please read INSTALL for compilation instructions.
......@@ -17,4 +17,4 @@ to subscribe to the lists or to visit the archives.
Enjoy,
Dimitri van Heesch (dimitri@stack.nl) (25 September 2007)
Dimitri van Heesch (dimitri@stack.nl) (26 October 2007)
1.4.5-20051109
1.5.4
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
/******************************************************************************
*
* $Id$
* $Id:$
*
*
* Copyright (C) 1997-2006 by Dimitri van Heesch.
......
#
#
# $Id$
#
# Copyright (C) 1997-2007 by Dimitri van Heesch.
#
......
#
#
# $Id$
#
# Copyright (C) 1997-2007 by Dimitri van Heesch.
#
......
......@@ -1103,10 +1103,14 @@ void MainWidget::launchWizard()
break;
}
#if defined(Q_OS_MACX)
if (Config_getBool("HAVE_DOT"))
if (Config_getString("DOT_PATH").isEmpty())
{
setDotPath();
}
if (Config_getString("MSCGEN_PATH").isEmpty())
{
setMscgenPath();
}
#endif
setConfigSaved(FALSE);
}
......@@ -1142,6 +1146,18 @@ void MainWidget::loadConfigFromFile(const QString &fn)
addRecentFile(fn);
m_workingDir->setText(QFileInfo(fn).dirPath(TRUE));
m_configFileName = fn;
#if defined(Q_OS_MACX)
if (Config_getString("DOT_PATH").isEmpty())
{
setDotPath();
setConfigSaved(FALSE);
}
if (Config_getString("MSCGEN_PATH").isEmpty())
{
setMscgenPath();
setConfigSaved(FALSE);
}
#endif
statusBar()->message("New configuration loaded",messageTimeout);
}
}
......@@ -1228,6 +1244,7 @@ void MainWidget::resetConfig()
Config::instance()->init();
#if defined(Q_OS_MACX)
setDotPath();
setMscgenPath();
#endif
m_configFileName = "";
......
#
#
# $Id$
#
# Copyright (C) 1997-2007 by Dimitri van Heesch.
#
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
char versionString[]="0.1";
char versionString[]="1.5.4";
/******************************************************************************
*
*
* $Id$
*
* Copyright (C) 1997-2007 by Dimitri van Heesch.
*
......
......@@ -17,10 +17,10 @@
doxygen_version_major=1
doxygen_version_minor=5
doxygen_version_revision=3
doxygen_version_revision=4
#NOTE: Setting version_mmn to "NO" will omit mmn info from the package.
doxygen_version_mmn=20070925
doxygen_version_mmn=NO
bin_dirs=`echo $PATH | sed -e "s/:/ /g"`
......
......@@ -84,6 +84,8 @@ documentation:
\refitem cmdfdollar \\f\$
\refitem cmdfbropen \\f[
\refitem cmdfbrclose \\f]
\refitem cmdfcurlyopen \\f{
\refitem cmdfcurlyclose \\f}
\refitem cmdfile \\file
\refitem cmdfn \\fn
\refitem cmdhideinitializer \\hideinitializer
......@@ -1974,6 +1976,19 @@ class Receiver
centered on a separate line.
\sa section \ref cmdfbropen "\\f[" and section \ref formulas "formulas".
<hr>
\section cmdfcurlyopen \\f{environment}{
Marks the start of a formula that is in a specific environment.
\note The second \{ is optional and is only to help editors (such as Vim) to
do proper syntax highlighting by making the number of opening and closing braces
the same.
<hr>
\section cmdfcurlyclose \\f}
Marks the end of a formula that is in a specific environment.
<hr>
\section cmdhtmlonly \\htmlonly
......
......@@ -214,6 +214,7 @@ followed by the descriptions of the tags grouped by category.
\refitem cfg_template_relations TEMPLATE_RELATIONS
\refitem cfg_toc_expand TOC_EXPAND
\refitem cfg_treeview_width TREEVIEW_WIDTH
\refitem cfg_typedef_hides_struct TYPEDEF_HIDES_STRUCT
\refitem cfg_uml_look UML_LOOK
\refitem cfg_use_htags USE_HTAGS
\refitem cfg_use_pdflatex USE_PDFLATEX
......@@ -522,6 +523,17 @@ followed by the descriptions of the tags grouped by category.
\c NO to prevent subgrouping. Alternatively, this can be done per class using
the \ref cmdnosubgrouping "\\nosubgrouping" command.
\anchor cfg_typedef_hides_struct
<dt>\c TYPEDEF_HIDES_STRUCT <dd>
\addindex TYPEDEF_HIDES_STRUCT
When \c TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct (or union) is
documented as struct with the name of the typedef. So
<code>typedef struct TypeS {} TypeT</code>, will appear in the documentation as a struct
with name \c TypeT. When disabled the typedef will appear as a member of a file,
namespace, or class. And the struct will be named \c TypeS. This can typically
be useful for C code where the coding convention is that all structs are
typedef'ed and only the typedef is referenced never the struct's name.
</dl>
\section config_build Build related options
......
......@@ -75,7 +75,7 @@ There are three ways to include formulas in the documentation.
the corresponding end command is \\f}. Here is an example for an
equation array
\verbatim
\f{eqnarray*}
\f{eqnarray*}{
g &=& \frac{Gm_2}{r^2} \\
&=& \frac{(6.673 \times 10^{-11}\,\mbox{m}^3\,\mbox{kg}^{-1}\,
\mbox{s}^{-2})(5.9736 \times 10^{24}\,\mbox{kg})}{(6371.01\,\mbox{km})^2} \\
......
......@@ -175,6 +175,7 @@ Thanks go to:
given me a good start in writing doxygen.
<li>All people at Troll Tech, for creating a beautiful GUI Toolkit
(which is very useful as a Windows/Unix platform abstraction layer :-)
<li>Kevin McBride for maintaining the subversion reporsitory for doxygen.
<li>My brother Frank
for rendering the logos.
<li>Harm van der Heijden for adding HTML help support.
......
......@@ -172,9 +172,9 @@ when the translator was updated.
</tr>
<tr bgcolor="#ffffff">
<td>Korean</td>
<td>SooYoung Jung<br>Richard Kim</td>
<td>jung5000 at gmail dot com<br>ryk at dspwiz dot com</td>
<td>1.4.6</td>
<td>Kim Taedong<br>SooYoung Jung<br>Richard Kim</td>
<td>fly1004 at gmail dot com<br>jung5000 at gmail dot com<br>ryk at dspwiz dot com</td>
<td>up-to-date</td>
</tr>
<tr bgcolor="#ffffff">
<td>KoreanEn</td>
......@@ -322,7 +322,8 @@ when the translator was updated.
\hline
JapaneseEn & see the Japanese language & {\tt\tiny ~} & English based \\
\hline
Korean & SooYoung Jung & {\tt\tiny jung5000@gmail.com} & 1.4.6 \\
Korean & Kim Taedong & {\tt\tiny fly1004@gmail.com} & up-to-date \\
~ & SooYoung Jung & {\tt\tiny jung5000@gmail.com} & ~ \\
~ & Richard Kim & {\tt\tiny ryk@dspwiz.com} & ~ \\
\hline
KoreanEn & see the Korean language & {\tt\tiny ~} & English based \\
......
......@@ -8,7 +8,7 @@ German, Greek, Hungarian, Indonesian, Italian, Japanese (+En), Korean
(+En), Lithuanian, Norwegian, Persian, Polish, Portuguese, Romanian,
Russian, Serbian, Slovak, Slovene, Spanish, Swedish, and Ukrainian.
Of them, 15 translators are up-to-date, 18 translators are based on
Of them, 16 translators are up-to-date, 17 translators are based on
some adapter class, and 2 are English based.
----------------------------------------------------------------------
......@@ -17,7 +17,7 @@ alphabetically). This means that they derive from the Translator class
and they implement all 194 of the required methods. Anyway, there
still may be some details listed even for them:
TranslatorBrazilian -- The "translate me!" found in a comment.
TranslatorBrazilian
TranslatorCatalan
TranslatorChinese
TranslatorCroatian -- The "translate me!" found in a comment.
......@@ -30,6 +30,7 @@ still may be some details listed even for them:
TranslatorGreek -- The "translate me!" found in a comment.
TranslatorItalian -- The "translate me!" found in a comment.
TranslatorJapanese -- Remove the obsolete methods (never used).
TranslatorKorean
TranslatorRussian -- The "translate me!" found in a comment.
TranslatorSpanish
......@@ -45,7 +46,6 @@ must be implemented to become up-to-date:
TranslatorPersian 1.4.6 1 method to implement
TranslatorNorwegian 1.4.6 1 method to implement
TranslatorLithuanian 1.4.6 2 methods to implement
TranslatorKorean 1.4.6 2 methods to implement
TranslatorIndonesian 1.4.6 1 method to implement
TranslatorHungarian 1.4.6 2 methods to implement
TranslatorChinesetraditional 1.4.6 1 method to implement
......@@ -105,12 +105,6 @@ TranslatorArabic (TranslatorAdapter_1_4_6) 1 method to implement
virtual QCString trNoDescriptionAvailable()
TranslatorBrazilian (Translator)
-------------------
Implements 194 of the required methods.
TranslatorChinesetraditional (TranslatorAdapter_1_4_6) 1 method to implement
----------------------------
......@@ -356,17 +350,6 @@ TranslatorJapaneseEn (TranslatorEnglish) 189 methods to implement
virtual QCString latexLanguageSupportCommand()
TranslatorKorean (TranslatorAdapter_1_4_6) 2 methods to implement
----------------
Implements 192 of the required methods.
Missing methods (should be implemented):
virtual QCString trCallerGraph()
virtual QCString trEnumerationValueDocumentation()
TranslatorKoreanEn (TranslatorEnglish) 189 methods to implement
------------------
......
......@@ -89,11 +89,11 @@ know why.
Bugs are tracked in GNOME's <a href="http://bugzilla.gnome.org">bugzilla</a> database.
Before submitting a
<a href="http://bugzilla.gnome.org/enter_bug.cgi?product=doxygen">new bug</a>,
first
<a href="http://bugzilla.gnome.org/buglist.cgi?product=doxygen&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=NEEDINFO&bug_status=REOPENED&bug_status=VERIFIED&email1=&emailtype1=substring&emailassigned_to1=1&email2=&emailtype2=substring&emailreporter2=1&changedin=&chfieldfrom=&chfieldto=Now&chfieldvalue=&short_desc=&short_desc_type=substring&long_desc=&long_desc_type=substring&bug_file_loc=&bug_file_loc_type=substring&status_whiteboard=&status_whiteboard_type=substring&keywords=&keywords_type=anywords&op_sys_details=&op_sys_details_type=substring&version_details=&version_details_type=substring&cmdtype=doit&namedcmd=gnome-libs+past+20+days&newqueryname=&order=Reuse+same+sort+as+last+time&form_name=query">
check</a> if the same bug has already been submitted by others.
first <a href="http://bugzilla.gnome.org/query.cgi?format=advanced&product=doxygen">search</a>
through the database if the same bug has already been submitted by others (the doxygen
product will be preselected).
If you believe you have found a new bug,
please <a href="http://bugzilla.gnome.org/enter_bug.cgi?product=doxygen">file it</a>.
please <a href="http://bugzilla.gnome.org/enter_bug.cgi?product=doxygen">report it</a>.
If you are unsure whether or not something is a bug, please ask help
on the <a href="http://sourceforge.net/mail/?group_id=5971">users mailing list</a>
......@@ -103,7 +103,7 @@ If you send only a (vague) description of a bug, you are usually not very
helpful and it will cost me much more time to figure out what you mean.
In the worst-case your bug report may even be completely ignored by me, so
always try to include the following information in your bug report:
- The version of doxygen you are using (for instance 1.2.4, use
- The version of doxygen you are using (for instance 1.5.3, use
<code>doxygen --version</code> if you are not sure).
- The name and version number of your operating system (for instance
SuSE Linux 6.4)
......@@ -112,14 +112,14 @@ always try to include the following information in your bug report:
to keep it small (use <code>doxygen -s -u [configName]</code> to strip
the comments from an existing config file).
- The easiest (and often the only) way for me to fix bugs is if you can
send me a small example demonstrating the problem you have, so I can
attach a small example demonstrating the problem you have to the bug report, so I can
reproduce it on my machine. Please make sure the example is valid
source code (could potentially compile) and that the problem is really
captured by the example (I often get examples that do not trigger the
actual bug!). If you intend to send more than one file please zip or tar
the files together into a single file for easier processing.
When reporting a new bug you'll get a chance to attach a file to it
immediately \e after opening the bug.
Note that when reporting a new bug you'll get a chance to attach a file to it
only \e after submitting the initial bug description.
You can (and are encouraged to) add a patch for a bug. If you do so
please use PATCH as a keyword in the bug entry form.
......
PROJECT_NAME = "Python"
OUTPUT_DIRECTORY = docstring
EXTRACT_ALL = YES
GENERATE_LATEX = NO
GENERATE_MAN = NO
GENERATE_RTF = NO
......
"""Documentation for this module.
"""@package docstring
Documentation for this module.
More details.
"""
......
## Documentation for this module.
## @package pyexample
# Documentation for this module.
#
# More details.
......
This dir contains the for doxygen relavant parts of libpng-1.2.1
and zlib-1.1.3. See http://www.libpng.org/pub/png/
This dir contains the for doxygen relavant parts of libpng-1.2.22
and zlib-1.2.3. See http://www.libpng.org/pub/png/
/* adler32.c -- compute the Adler-32 checksum of a data stream
* Copyright (C) 1995-2002 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
* Copyright (C) 1995-2004 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* @(#) $Id$ */
#define ZLIB_INTERNAL
#include "zlib.h"
#define BASE 65521L /* largest prime smaller than 65536 */
#define BASE 65521UL /* largest prime smaller than 65536 */
#define NMAX 5552
/* NMAX is the largest n such that 255n(n+1)/2 + (n+1)(BASE-1) <= 2^32-1 */
#define DO1(buf,i) {s1 += buf[i]; s2 += s1;}
#define DO1(buf,i) {adler += (buf)[i]; sum2 += adler;}
#define DO2(buf,i) DO1(buf,i); DO1(buf,i+1);
#define DO4(buf,i) DO2(buf,i); DO2(buf,i+2);
#define DO8(buf,i) DO4(buf,i); DO4(buf,i+4);
#define DO16(buf) DO8(buf,0); DO8(buf,8);
/* use NO_DIVIDE if your processor does not do division in hardware */
#ifdef NO_DIVIDE
# define MOD(a) \
do { \
if (a >= (BASE << 16)) a -= (BASE << 16); \
if (a >= (BASE << 15)) a -= (BASE << 15); \
if (a >= (BASE << 14)) a -= (BASE << 14); \
if (a >= (BASE << 13)) a -= (BASE << 13); \
if (a >= (BASE << 12)) a -= (BASE << 12); \
if (a >= (BASE << 11)) a -= (BASE << 11); \
if (a >= (BASE << 10)) a -= (BASE << 10); \
if (a >= (BASE << 9)) a -= (BASE << 9); \
if (a >= (BASE << 8)) a -= (BASE << 8); \
if (a >= (BASE << 7)) a -= (BASE << 7); \
if (a >= (BASE << 6)) a -= (BASE << 6); \
if (a >= (BASE << 5)) a -= (BASE << 5); \
if (a >= (BASE << 4)) a -= (BASE << 4); \
if (a >= (BASE << 3)) a -= (BASE << 3); \
if (a >= (BASE << 2)) a -= (BASE << 2); \
if (a >= (BASE << 1)) a -= (BASE << 1); \
if (a >= BASE) a -= BASE; \
} while (0)
# define MOD4(a) \
do { \
if (a >= (BASE << 4)) a -= (BASE << 4); \
if (a >= (BASE << 3)) a -= (BASE << 3); \
if (a >= (BASE << 2)) a -= (BASE << 2); \
if (a >= (BASE << 1)) a -= (BASE << 1); \
if (a >= BASE) a -= BASE; \
} while (0)
#else
# define MOD(a) a %= BASE
# define MOD4(a) a %= BASE
#endif
/* ========================================================================= */
uLong ZEXPORT adler32(uLong adler, const Bytef *buf, uInt len)
uLong ZEXPORT adler32(adler, buf, len)
uLong adler;
const Bytef *buf;
uInt len;
{
unsigned long s1 = adler & 0xffff;
unsigned long s2 = (adler >> 16) & 0xffff;
int k;
unsigned long sum2;
unsigned n;
/* split Adler-32 into component sums */
sum2 = (adler >> 16) & 0xffff;
adler &= 0xffff;
/* in case user likes doing a byte at a time, keep it fast */
if (len == 1) {
adler += buf[0];
if (adler >= BASE)
adler -= BASE;
sum2 += adler;
if (sum2 >= BASE)
sum2 -= BASE;
return adler | (sum2 << 16);
}
/* initial Adler-32 value (deferred check for len == 1 speed) */
if (buf == Z_NULL)
return 1L;
/* in case short lengths are provided, keep it somewhat fast */
if (len < 16) {
while (len--) {
adler += *buf++;
sum2 += adler;
}
if (adler >= BASE)
adler -= BASE;
MOD4(sum2); /* only added so many BASE's */
return adler | (sum2 << 16);
}
if (buf == Z_NULL) return 1L;
/* do length NMAX blocks -- requires just one modulo operation */
while (len >= NMAX) {
len -= NMAX;
n = NMAX / 16; /* NMAX is divisible by 16 */
do {
DO16(buf); /* 16 sums unrolled */
buf += 16;
} while (--n);
MOD(adler);
MOD(sum2);
}
while (len > 0) {
k = len < NMAX ? len : NMAX;
len -= k;
while (k >= 16) {
/* do remaining bytes (less than NMAX, still just one modulo) */
if (len) { /* avoid modulos if none remaining */
while (len >= 16) {
len -= 16;
DO16(buf);
buf += 16;
k -= 16;
buf += 16;
}
while (len--) {
adler += *buf++;
sum2 += adler;
}
if (k != 0) do {
s1 += *buf++;
s2 += s1;
} while (--k);
s1 %= BASE;
s2 %= BASE;
MOD(adler);
MOD(sum2);
}
return (s2 << 16) | s1;
/* return recombined sums */
return adler | (sum2 << 16);
}
/* ========================================================================= */
uLong ZEXPORT adler32_combine(adler1, adler2, len2)
uLong adler1;
uLong adler2;
z_off_t len2;
{
unsigned long sum1;
unsigned long sum2;
unsigned rem;
/* the derivation of this formula is left as an exercise for the reader */
rem = (unsigned)(len2 % BASE);
sum1 = adler1 & 0xffff;
sum2 = rem * sum1;
MOD(sum2);
sum1 += (adler2 & 0xffff) + BASE - 1;
sum2 += ((adler1 >> 16) & 0xffff) + ((adler2 >> 16) & 0xffff) + BASE - rem;
if (sum1 > BASE) sum1 -= BASE;
if (sum1 > BASE) sum1 -= BASE;
if (sum2 > (BASE << 1)) sum2 -= (BASE << 1);
if (sum2 > BASE) sum2 -= BASE;
return sum1 | (sum2 << 16);
}
/* compress.c -- compress a memory buffer
* Copyright (C) 1995-2002 Jean-loup Gailly.
* For conditions of distribution and use, see copyright notice in zlib.h
* Copyright (C) 1995-2003 Jean-loup Gailly.
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* @(#) $Id$ */
#define ZLIB_INTERNAL
#include "zlib.h"
/* ===========================================================================
......@@ -18,7 +19,12 @@
memory, Z_BUF_ERROR if there was not enough room in the output buffer,
Z_STREAM_ERROR if the level parameter is invalid.
*/
int ZEXPORT compress2 (Bytef *dest, uLongf *destLen, const Bytef *source, uLong sourceLen, int level)
int ZEXPORT compress2 (dest, destLen, source, sourceLen, level)
Bytef *dest;
uLongf *destLen;
const Bytef *source;
uLong sourceLen;
int level;
{
z_stream stream;
int err;
......@@ -53,7 +59,21 @@ int ZEXPORT compress2 (Bytef *dest, uLongf *destLen, const Bytef *source, uLong
/* ===========================================================================
*/
int ZEXPORT compress (Bytef *dest, uLongf *destLen, const Bytef *source, uLong sourceLen)
int ZEXPORT compress (dest, destLen, source, sourceLen)
Bytef *dest;
uLongf *destLen;
const Bytef *source;
uLong sourceLen;
{
return compress2(dest, destLen, source, sourceLen, Z_DEFAULT_COMPRESSION);
}
/* ===========================================================================
If the default memLevel or windowBits for deflateInit() is changed, then
this function needs to be updated.
*/
uLong ZEXPORT compressBound (sourceLen)
uLong sourceLen;
{
return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + 11;
}
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/* deflate.h -- internal compression state
* Copyright (C) 1995-2002 Jean-loup Gailly
* For conditions of distribution and use, see copyright notice in zlib.h
* Copyright (C) 1995-2004 Jean-loup Gailly
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* WARNING: this file should *not* be used by applications. It is
......@@ -10,11 +10,19 @@
/* @(#) $Id$ */
#ifndef _DEFLATE_H
#define _DEFLATE_H
#ifndef DEFLATE_H
#define DEFLATE_H
#include "zutil.h"
/* define NO_GZIP when compiling if you want to disable gzip header and
trailer creation by deflate(). NO_GZIP would be used to avoid linking in
the crc code when it is not needed. For shared libraries, gzip encoding
should be left enabled. */
#ifndef NO_GZIP
# define GZIP
#endif
/* ===========================================================================
* Internal compression state.
*/
......@@ -41,6 +49,10 @@
/* All codes must not exceed MAX_BITS bits */
#define INIT_STATE 42
#define EXTRA_STATE 69
#define NAME_STATE 73
#define COMMENT_STATE 91
#define HCRC_STATE 103
#define BUSY_STATE 113
#define FINISH_STATE 666
/* Stream status */
......@@ -85,9 +97,10 @@ typedef struct internal_state {
Bytef *pending_buf; /* output still pending */
ulg pending_buf_size; /* size of pending_buf */
Bytef *pending_out; /* next pending byte to output to the stream */
int pending; /* nb of bytes in the pending buffer */
int noheader; /* suppress zlib header and adler32 */
Byte data_type; /* UNKNOWN, BINARY or ASCII */
uInt pending; /* nb of bytes in the pending buffer */
int wrap; /* bit 0 true for zlib, bit 1 true for gzip */
gz_headerp gzhead; /* gzip header information to write */
uInt gzindex; /* where in extra, name, or comment */
Byte method; /* STORED (for zip only) or DEFLATED */
int last_flush; /* value of flush param for previous deflate call */
......@@ -269,7 +282,7 @@ typedef struct internal_state {
void _tr_init OF((deflate_state *s));
int _tr_tally OF((deflate_state *s, unsigned dist, unsigned lc));
void _tr_flush_block OF((deflate_state *s, charf *buf, ulg stored_len,
int eof));
int eof));
void _tr_align OF((deflate_state *s));
void _tr_stored_block OF((deflate_state *s, charf *buf, ulg stored_len,
int eof));
......@@ -312,7 +325,7 @@ void _tr_stored_block OF((deflate_state *s, charf *buf, ulg stored_len,
#else
# define _tr_tally_lit(s, c, flush) flush = _tr_tally(s, 0, c)
# define _tr_tally_dist(s, distance, length, flush) \
flush = _tr_tally(s, distance, length)
flush = _tr_tally(s, distance, length)
#endif
#endif
#endif /* DEFLATE_H */
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
/* inffast.h -- header to use inffast.c
* Copyright (C) 1995-2002 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
* Copyright (C) 1995-2003 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* WARNING: this file should *not* be used by applications. It is
......@@ -8,10 +8,4 @@
subject to change. Applications should only use zlib.h.
*/
extern int inflate_fast OF((
uInt,
uInt,
inflate_huft *,
inflate_huft *,
inflate_blocks_statef *,
z_streamp ));
void inflate_fast OF((z_streamp strm, unsigned start));
This diff is collapsed.
This diff is collapsed.
/* inflate.h -- internal inflate state definition
* Copyright (C) 1995-2004 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* WARNING: this file should *not* be used by applications. It is
part of the implementation of the compression library and is
subject to change. Applications should only use zlib.h.
*/
/* define NO_GZIP when compiling if you want to disable gzip header and
trailer decoding by inflate(). NO_GZIP would be used to avoid linking in
the crc code when it is not needed. For shared libraries, gzip decoding
should be left enabled. */
#ifndef NO_GZIP
# define GUNZIP
#endif
/* Possible inflate modes between inflate() calls */
typedef enum {
HEAD, /* i: waiting for magic header */
FLAGS, /* i: waiting for method and flags (gzip) */
TIME, /* i: waiting for modification time (gzip) */
OS, /* i: waiting for extra flags and operating system (gzip) */
EXLEN, /* i: waiting for extra length (gzip) */
EXTRA, /* i: waiting for extra bytes (gzip) */
NAME, /* i: waiting for end of file name (gzip) */
COMMENT, /* i: waiting for end of comment (gzip) */
HCRC, /* i: waiting for header crc (gzip) */
DICTID, /* i: waiting for dictionary check value */
DICT, /* waiting for inflateSetDictionary() call */
TYPE, /* i: waiting for type bits, including last-flag bit */
TYPEDO, /* i: same, but skip check to exit inflate on new block */
STORED, /* i: waiting for stored size (length and complement) */
COPY, /* i/o: waiting for input or output to copy stored block */
TABLE, /* i: waiting for dynamic block table lengths */
LENLENS, /* i: waiting for code length code lengths */
CODELENS, /* i: waiting for length/lit and distance code lengths */
LEN, /* i: waiting for length/lit code */
LENEXT, /* i: waiting for length extra bits */
DIST, /* i: waiting for distance code */
DISTEXT, /* i: waiting for distance extra bits */
MATCH, /* o: waiting for output space to copy string */
LIT, /* o: waiting for output space to write literal */
CHECK, /* i: waiting for 32-bit check value */
LENGTH, /* i: waiting for 32-bit length (gzip) */
DONE, /* finished check, done -- remain here until reset */
BAD, /* got a data error -- remain here until reset */
MEM, /* got an inflate() memory error -- remain here until reset */
SYNC /* looking for synchronization bytes to restart inflate() */
} inflate_mode;
/*
State transitions between above modes -
(most modes can go to the BAD or MEM mode -- not shown for clarity)
Process header:
HEAD -> (gzip) or (zlib)
(gzip) -> FLAGS -> TIME -> OS -> EXLEN -> EXTRA -> NAME
NAME -> COMMENT -> HCRC -> TYPE
(zlib) -> DICTID or TYPE
DICTID -> DICT -> TYPE
Read deflate blocks:
TYPE -> STORED or TABLE or LEN or CHECK
STORED -> COPY -> TYPE
TABLE -> LENLENS -> CODELENS -> LEN
Read deflate codes:
LEN -> LENEXT or LIT or TYPE
LENEXT -> DIST -> DISTEXT -> MATCH -> LEN
LIT -> LEN
Process trailer:
CHECK -> LENGTH -> DONE
*/
/* state maintained between inflate() calls. Approximately 7K bytes. */
struct inflate_state {
inflate_mode mode; /* current inflate mode */
int last; /* true if processing last block */
int wrap; /* bit 0 true for zlib, bit 1 true for gzip */
int havedict; /* true if dictionary provided */
int flags; /* gzip header method and flags (0 if zlib) */
unsigned dmax; /* zlib header max distance (INFLATE_STRICT) */
unsigned long check; /* protected copy of check value */
unsigned long total; /* protected copy of output count */
gz_headerp head; /* where to save gzip header information */
/* sliding window */
unsigned wbits; /* log base 2 of requested window size */
unsigned wsize; /* window size or zero if not using window */
unsigned whave; /* valid bytes in the window */
unsigned write; /* window write index */
unsigned char FAR *window; /* allocated sliding window, if needed */
/* bit accumulator */
unsigned long hold; /* input bit accumulator */
unsigned bits; /* number of bits in "in" */
/* for string and stored block copying */
unsigned length; /* literal or length of data to copy */
unsigned offset; /* distance back to copy string from */
/* for table and code decoding */
unsigned extra; /* extra bits needed */
/* fixed and dynamic code tables */
code const FAR *lencode; /* starting table for length/literal codes */
code const FAR *distcode; /* starting table for distance codes */
unsigned lenbits; /* index bits for lencode */
unsigned distbits; /* index bits for distcode */
/* dynamic table building */
unsigned ncode; /* number of code length code lengths */
unsigned nlen; /* number of length code lengths */
unsigned ndist; /* number of distance code lengths */
unsigned have; /* number of code lengths in lens[] */
code FAR *next; /* next available space in codes[] */
unsigned short lens[320]; /* temporary storage for code lengths */
unsigned short work[288]; /* work area for code table building */
code codes[ENOUGH]; /* space for code tables */
};
This diff is collapsed.
/* inftrees.h -- header to use inftrees.c
* Copyright (C) 1995-2002 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
* Copyright (C) 1995-2005 Mark Adler
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* WARNING: this file should *not* be used by applications. It is
......@@ -8,51 +8,48 @@
subject to change. Applications should only use zlib.h.
*/
/* Huffman code lookup table entry--this entry is four bytes for machines
that have 16-bit pointers (e.g. PC's in the small or medium model). */
typedef struct inflate_huft_s FAR inflate_huft;
struct inflate_huft_s {
union {
struct {
Byte Exop; /* number of extra bits or operation */
Byte Bits; /* number of bits in this code or subcode */
} what;
uInt pad; /* pad structure to a power of 2 (4 bytes for */
} word; /* 16-bit, 8 bytes for 32-bit int's) */
uInt base; /* literal, length base, distance base,
or table offset */
};
/* Structure for decoding tables. Each entry provides either the
information needed to do the operation requested by the code that
indexed that table entry, or it provides a pointer to another
table that indexes more bits of the code. op indicates whether
the entry is a pointer to another table, a literal, a length or
distance, an end-of-block, or an invalid code. For a table
pointer, the low four bits of op is the number of index bits of
that table. For a length or distance, the low four bits of op
is the number of extra bits to get after the code. bits is
the number of bits in this code or part of the code to drop off
of the bit buffer. val is the actual byte to output in the case
of a literal, the base length or distance, or the offset from
the current table to the next table. Each entry is four bytes. */
typedef struct {
unsigned char op; /* operation, extra bits, table bits */
unsigned char bits; /* bits in this part of the code */
unsigned short val; /* offset in table or code value */
} code;
/* op values as set by inflate_table():
00000000 - literal
0000tttt - table link, tttt != 0 is the number of table index bits
0001eeee - length or distance, eeee is the number of extra bits
01100000 - end of block
01000000 - invalid code
*/
/* Maximum size of dynamic tree. The maximum found in a long but non-
exhaustive search was 1004 huft structures (850 for length/literals
and 154 for distances, the latter actually the result of an
exhaustive search). The actual maximum is not known, but the
value below is more than safe. */
#define MANY 1440
extern int inflate_trees_bits OF((
uIntf *, /* 19 code lengths */
uIntf *, /* bits tree desired/actual depth */
inflate_huft * FAR *, /* bits tree result */
inflate_huft *, /* space for trees */
z_streamp)); /* for messages */
extern int inflate_trees_dynamic OF((
uInt, /* number of literal/length codes */
uInt, /* number of distance codes */
uIntf *, /* that many (total) code lengths */
uIntf *, /* literal desired/actual bit depth */
uIntf *, /* distance desired/actual bit depth */
inflate_huft * FAR *, /* literal/length tree result */
inflate_huft * FAR *, /* distance tree result */
inflate_huft *, /* space for trees */
z_streamp)); /* for messages */
extern int inflate_trees_fixed OF((
uIntf *, /* literal desired/actual bit depth */
uIntf *, /* distance desired/actual bit depth */
inflate_huft * FAR *, /* literal/length tree result */
inflate_huft * FAR *, /* distance tree result */
z_streamp)); /* for memory allocation */
exhaustive search was 1444 code structures (852 for length/literals
and 592 for distances, the latter actually the result of an
exhaustive search). The true maximum is not known, but the value
below is more than safe. */
#define ENOUGH 2048
#define MAXD 592
/* Type of code to build for inftable() */
typedef enum {
CODES,
LENS,
DISTS
} codetype;
extern int inflate_table OF((codetype type, unsigned short FAR *lens,
unsigned codes, code FAR * FAR *table,
unsigned FAR *bits, unsigned short FAR *work));
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment