Commit 572dccaa authored by Alessandro Ghedini's avatar Alessandro Ghedini

Imported Upstream version 2.2.0+git20160802

parent 9a4e0454
......@@ -8,6 +8,7 @@ BINDIR=@exedir@
MANDIR=@mandir@
LIBDIR=@libdir@
INCDIR=@prefix@/include
PKGDIR=$(LIBDIR)/pkgconfig
PGMS=markdown
SAMPLE_PGMS=mkd2html makepage
......@@ -23,10 +24,11 @@ MAN3PAGES=mkd-callbacks.3 mkd-functions.3 markdown.3 mkd-line.3
all: $(PGMS) $(SAMPLE_PGMS) $(TESTFRAMEWORK)
install: $(PGMS) $(DESTDIR)$(BINDIR) $(DESTDIR)$(LIBDIR) $(DESTDIR)$(INCDIR)
install: $(PGMS) $(DESTDIR)$(BINDIR) $(DESTDIR)$(LIBDIR) $(DESTDIR)$(INCDIR) $(DESTDIR)$(PKGDIR)
@INSTALL_PROGRAM@ $(PGMS) $(DESTDIR)$(BINDIR)
./librarian.sh install libmarkdown VERSION $(DESTDIR)$(LIBDIR)
@INSTALL_DATA@ mkdio.h $(DESTDIR)$(INCDIR)
@INSTALL_DATA@ $(MKDLIB).pc $(DESTDIR)$(PKGDIR)
install.everything: install install.samples install.man
......@@ -65,13 +67,16 @@ $(DESTDIR)$(INCDIR):
$(DESTDIR)$(LIBDIR):
@INSTALL_DIR@ $(DESTDIR)$(LIBDIR)
$(DESTDIR)$(PKGDIR): $(DESTDIR)$(LIBDIR)
@INSTALL_DIR@ $(DESTDIR)$(PKGDIR)
version.o: version.c VERSION
$(CC) $(CFLAGS) -DVERSION=\"`cat VERSION`\" -c version.c
VERSION:
@true
tags.o: tags.c blocktags
tags.o: tags.c cstring.h tags.h blocktags
blocktags: mktags
./mktags > blocktags
......@@ -139,3 +144,5 @@ toc.o: toc.c config.h cstring.h amalloc.h markdown.h
version.o: version.c config.h
xml.o: xml.c config.h cstring.h amalloc.h markdown.h
xmlpage.o: xmlpage.c config.h cstring.h amalloc.h markdown.h
setup.o: setup.c config.h cstring.h amalloc.h markdown.h
github_flavoured.o: github_flavoured.c config.h cstring.h amalloc.h markdown.h
......@@ -5,6 +5,7 @@
#include <stdio.h>
#include <stdlib.h>
#include "config.h"
#define MAGIC 0x1f2e3d4c
......
......@@ -876,13 +876,25 @@ AC_SCALAR_TYPES () {
rc=1
LOGN "defining WORD & DWORD scalar types"
if AC_QUIET AC_CHECK_HEADERS WinDef.h; then
# windows machine; BYTE, WORD, DWORD already
# defined
echo "#include <WinDef.h>" >> "$__cwd"/config.h
TLOG " (defined in WinDef.h)"
return 0
fi
# --- is this needed anymore? ---
# if AC_QUIET AC_CHECK_HEADERS WinDef.h; then
# # windows machine; BYTE, WORD, DWORD already
# # defined
#
# for x in $@; do
# case "$x" in
# sub)AC_SUB DWORD DWORD
# AC_SUB WORD WORD
# AC_SUB BYTE BYTE
# ;;
# *)
# echo "#include <WinDef.h>" >> "$__cwd"/config.h
# ;;
# esac
# done
# TLOG " (defined in WinDef.h)"
# return 0
# fi
cat > ngc$$.c << EOF
#include <stdio.h>
......
......@@ -9,8 +9,6 @@
#
ac_help='--enable-amalloc Enable memory allocation debugging
--with-tabstops=N Set tabstops to N characters (default is 4)
--with-latex Enable latex passthrough
--enable-all-features Turn on all stable optional features
--shared Build shared libraries (default is static)'
LOCAL_AC_OPTIONS='
......@@ -28,9 +26,6 @@ locals() {
--SHARED)
echo TRY_SHARED=T
;;
--ENABLE-ALL|--ENABLE-ALL-FEATURES)
echo WITH_AMALLOC=T
;;
--ENABLE-*) enable=`echo $K | sed -e 's/--ENABLE-//' | tr '-' '_'`
echo WITH_${enable}=T ;;
--DEBIAN-GLITCH)
......@@ -39,10 +34,13 @@ locals() {
esac
}
VERSION=`cat VERSION`
TARGET=markdown
. ./configure.inc
AC_INIT $TARGET
AC_SUB 'PACKAGE_NAME' lib$TARGET
AC_SUB 'PACKAGE_VERSION' $VERSION
for banned_with in dl fenced-code id-anchor github-tags urlencoded-anchor; do
banned_with_variable_ref=\$WITH_`echo "$banned_with" | $AC_UPPERCASE | tr - _`
......@@ -163,6 +161,5 @@ fi
[ "$OS_FREEBSD" -o "$OS_DRAGONFLY" ] || AC_CHECK_HEADERS malloc.h
[ "$WITH_PANDOC_HEADER" ] && AC_DEFINE 'PANDOC_HEADER' '1'
[ "$WITH_LATEX" ] && AC_DEFINE 'WITH_LATEX' '1'
AC_OUTPUT Makefile version.c mkdio.h
AC_OUTPUT Makefile version.c mkdio.h libmarkdown.pc
......@@ -36,6 +36,7 @@ static struct flagnames flagnames[] = {
{ MKD_IDANCHOR, "IDANCHOR" },
{ MKD_GITHUBTAGS, "GITHUBTAGS" },
{ MKD_URLENCODEDANCHOR, "URLENCODEDANCHOR" },
{ MKD_LATEX, "LATEX" },
};
#define NR(x) (sizeof x/sizeof x[0])
......
......@@ -50,22 +50,22 @@ pushc(char c, MMIOT *f)
/* look <i> characters ahead of the cursor.
*/
static inline int
static inline unsigned int
peek(MMIOT *f, int i)
{
i += (f->isp-1);
return (i >= 0) && (i < S(f->in)) ? T(f->in)[i] : EOF;
return (i >= 0) && (i < S(f->in)) ? (unsigned char)T(f->in)[i] : EOF;
}
/* pull a byte from the input buffer
*/
static inline int
static inline unsigned int
pull(MMIOT *f)
{
return ( f->isp < S(f->in) ) ? T(f->in)[f->isp++] : EOF;
return ( f->isp < S(f->in) ) ? (unsigned char)T(f->in)[f->isp++] : EOF;
}
......@@ -1207,7 +1207,6 @@ smartypants(int c, int *flags, MMIOT *f)
} /* smartypants */
#if WITH_LATEX
/* process latex with arbitrary 2-character ( $$ .. $$, \[ .. \], \( .. \)
* delimiters
*/
......@@ -1227,7 +1226,6 @@ mathhandler(MMIOT *f, int e1, int e2)
}
return 0;
}
#endif
/* process a body of text encased in some sort of tick marks. If it
......@@ -1410,12 +1408,11 @@ text(MMIOT *f)
case EOF: Qchar('\\', f);
break;
#if WITH_LATEX
case '[':
case '(': if ( mathhandler(f, '\\', (c =='(')?')':']') )
case '(': if ( (f->flags & MKD_LATEX)
&& mathhandler(f, '\\', (c =='(')?')':']') )
break;
/* else fall through to default */
#endif
default: if ( escaped(f,c) ||
strchr(">#.-+{}]![*_\\()`", c) )
......@@ -1442,15 +1439,13 @@ text(MMIOT *f)
Qchar(c, f);
break;
#if WITH_LATEX
case '$': if ( peek(f, 1) == '$' ) {
case '$': if ( (f->flags & MKD_LATEX) && (peek(f, 1) == '$') ) {
pull(f);
if ( mathhandler(f, '$', '$') )
break;
Qchar('$', f);
}
/* fall through to default */
#endif
default: Qchar(c, f);
break;
......
prefix=@prefix@
exec_prefix=@prefix@
libdir=@libdir@
includedir=@prefix@/include
Name: @PACKAGE_NAME@
Version: @PACKAGE_VERSION@
Description: C implementation of John Gruber's Markdown markup language
Libs: -L${libdir} -lmarkdown @LIBS@
Cflags: -I${includedir}
......@@ -73,8 +73,8 @@ char **argv;
exit(0);
}
if ( (argc > 1) && !freopen(argv[1], "r", stdin) ) {
perror(argv[1]);
if ( (argc > 0) && !freopen(argv[0], "r", stdin) ) {
perror(argv[0]);
exit(1);
}
......
#ifndef _MARKDOWN_D
#define _MARKDOWN_D
#include "config.h"
#include "cstring.h"
/* reference-style links (and images) are stored in an array
......@@ -49,7 +50,8 @@ typedef struct paragraph {
struct paragraph *down; /* recompiled contents of this paragraph */
struct line *text; /* all the text in this paragraph */
char *ident; /* %id% tag for QUOTE */
char *lang; /* lang attribute for CODE */
char *lang; /* lang attribute for CODE */
char *label; /* label for TOC */
enum { WHITESPACE=0, CODE, QUOTE, MARKUP,
HTML, STYLE, DL, UL, OL, AL, LISTITEM,
HDR, HR, TABLE, SOURCE } typ;
......@@ -136,7 +138,8 @@ typedef struct mmiot {
#define MKD_GITHUBTAGS 0x08000000
#define MKD_URLENCODEDANCHOR 0x10000000
#define IS_LABEL 0x20000000
#define USER_FLAGS 0x3FFFFFFF
#define MKD_LATEX 0x40000000
#define USER_FLAGS 0x7FFFFFFF
#define INPUT_MASK (MKD_NOHEADER|MKD_TABSTOP)
Callback_data *cb;
......
......@@ -112,6 +112,7 @@ void mkd_ref_prefix(MMIOT*, char*);
#define MKD_IDANCHOR 0x04000000 /* use id= anchors for TOC links */
#define MKD_GITHUBTAGS 0x08000000 /* allow dash and underscore in element names */
#define MKD_URLENCODEDANCHOR 0x10000000 /* urlencode non-identifier chars instead of replacing with dots */
#define MKD_LATEX 0x40000000 /* handle embedded LaTeX escapes */
#define MKD_EMBED MKD_NOLINKS|MKD_NOIMAGE|MKD_TAGTEXT
......
......@@ -61,6 +61,7 @@ static struct _opt {
{ "idanchor", "id= anchors in TOC", 0, 0, 1, MKD_IDANCHOR },
{ "githubtags", "permit - and _ in element names", 0, 0, 0, MKD_GITHUBTAGS },
{ "urlencodedanchor", "urlencode special chars in TOC links", 0, 0, 0, MKD_URLENCODEDANCHOR },
{ "latex", "handle LaTeX escapes", 0, 0, 1, MKD_LATEX },
} ;
#define NR(x) (sizeof x / sizeof x[0])
......
. tests/functions.sh
# don't run these tests unless --with-latex
./markdown -V | grep LATEX >/dev/null || exit 0
title "embedded latex"
rc=0
MARKDOWN_FLAGS=
try 'latex w/ \( .. \)' '\(\tex\)' '<p>\(\tex\)</p>'
try 'latex w/ \( .. \) and link inside' '\([(1+2)*3-4](1-2)\)' '<p>\([(1+2)*3-4](1-2)\)</p>'
try 'latex w/ \( .. \) and special characters' 'Equation:\(a<+>b\).' \
try -flatex 'latex w/ \( .. \)' '\(\tex\)' '<p>\(\tex\)</p>'
try -flatex 'latex w/ \( .. \) and link inside' '\([(1+2)*3-4](1-2)\)' '<p>\([(1+2)*3-4](1-2)\)</p>'
try -flatex 'latex w/ \( .. \) and special characters' 'Equation:\(a<+>b\).' \
'<p>Equation:\(a&lt;+&gt;b\).</p>'
try 'latex $ delimiter not supported' '$[a](b)$' '<p>$<a href="b">a</a>$</p>'
try -flatex 'latex $ delimiter not supported' '$[a](b)$' '<p>$<a href="b">a</a>$</p>'
try 'latex with $$ .. $$' '$$foo$$' '<p>$$foo$$</p>'
try 'latex with $$ .. $$ like a link' '$$[(1+2)*3-4](1-2)$$' '<p>$$[(1+2)*3-4](1-2)$$</p>'
try 'latex with multiple $$ .. $$' '$$[a](b)$$$$[a](b)$$' '<p>$$[a](b)$$$$[a](b)$$</p>'
try 'latex with $$ .. $$ and a real link' '$$[a](b)$$[a](b)$$' '<p>$$[a](b)$$<a href="b">a</a>$$</p>'
try 'latex with $$ .. $$ and a real link' '$$[a](b)$$$[a](b)$$' '<p>$$[a](b)$$$<a href="b">a</a>$$</p>'
try 'latex with $$ .. $$ multi lines' '$$\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} & = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} & = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} & = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} & = 0 \end{split}$$' '<p>$$\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} &amp; = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} &amp; = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} &amp; = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} &amp; = 0 \end{split}$$</p>'
try -flatex 'latex with $$ .. $$' '$$foo$$' '<p>$$foo$$</p>'
try -flatex 'latex with $$ .. $$ like a link' '$$[(1+2)*3-4](1-2)$$' '<p>$$[(1+2)*3-4](1-2)$$</p>'
try -flatex 'latex with multiple $$ .. $$' '$$[a](b)$$$$[a](b)$$' '<p>$$[a](b)$$$$[a](b)$$</p>'
try -flatex 'latex with $$ .. $$ and a real link' '$$[a](b)$$[a](b)$$' '<p>$$[a](b)$$<a href="b">a</a>$$</p>'
try -flatex 'latex with $$ .. $$ and a real link' '$$[a](b)$$$[a](b)$$' '<p>$$[a](b)$$$<a href="b">a</a>$$</p>'
try -flatex 'latex with $$ .. $$ multi lines' '$$\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} & = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} & = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} & = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} & = 0 \end{split}$$' '<p>$$\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} &amp; = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} &amp; = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} &amp; = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} &amp; = 0 \end{split}$$</p>'
try 'latex with \[ .. \]' '\[foo\]' '<p>\[foo\]</p>'
try 'latex with \[ .. \] and link inside' '\[[(1+2)*3-4](1-2)\]' '<p>\[[(1+2)*3-4](1-2)\]</p>'
try 'latex with \[ .. \] multi lines' '\[\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} & = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} & = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} & = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} & = 0 \end{split}\]' '<p>\[\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} &amp; = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} &amp; = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} &amp; = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} &amp; = 0 \end{split}\]</p>'
try -flatex 'latex with \[ .. \]' '\[foo\]' '<p>\[foo\]</p>'
try -flatex 'latex with \[ .. \] and link inside' '\[[(1+2)*3-4](1-2)\]' '<p>\[[(1+2)*3-4](1-2)\]</p>'
try -flatex 'latex with \[ .. \] multi lines' '\[\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} & = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} & = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} & = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} & = 0 \end{split}\]' '<p>\[\begin{split}\nabla \times \vec{\mathbf{B}} -\, \frac1c\, \frac{\partial\vec{\mathbf{E}}}{\partial t} &amp; = \frac{4\pi}{c}\vec{\mathbf{j}} \\ \nabla \cdot \vec{\mathbf{E}} &amp; = 4 \pi \rho \\ \nabla \times \vec{\mathbf{E}}\, +\, \frac1c\, \frac{\partial\vec{\mathbf{B}}}{\partial t} &amp; = \vec{\mathbf{0}} \\ \nabla \cdot \vec{\mathbf{B}} &amp; = 0 \end{split}\]</p>'
summary $0
exit $rc
......@@ -5,140 +5,140 @@ title "data corruption cases from Fernando Muñoz"
rc=0
MARKDOWN_FLAGS=
try 'id_000002_06' '<p></
try 'id_000002_06' '<p></
>0' '<p><p>&lt;/</p>
<blockquote><p>0</p></blockquote>'
try 'id_000009_06' '<pre
try 'id_000009_06' '<pre
</pr>0' '<p><pre
</pr>0</p>'
try 'id_000010_06' '<pre></pr>>' '<p><pre></pr>></p>'
try 'id_000014_06' '<div></di>-' '<p><div></di>-</p>'
try 'id_000015_06' '<div></di>>' '<p><div></di>></p>'
try 'id_000018_06' '<div></di>#0' '<p><div></di>#0</p>'
try 'id_000029_06' '<div </di>#0' '<p><div </di>#0</p>'
try 'id_000031_06' '<div </di>>' '<p><div </di>></p>'
try 'id_000032_06' '<div <di </di></di>*' '<p><div <di </di></di>*</p>'
try 'id_000038_06' '<p>
try 'id_000010_06' '<pre></pr>>' '<p><pre></pr>></p>'
try 'id_000014_06' '<div></di>-' '<p><div></di>-</p>'
try 'id_000015_06' '<div></di>>' '<p><div></di>></p>'
try 'id_000018_06' '<div></di>#0' '<p><div></di>#0</p>'
try 'id_000029_06' '<div </di>#0' '<p><div </di>#0</p>'
try 'id_000031_06' '<div </di>>' '<p><div </di>></p>'
try 'id_000032_06' '<div <di </di></di>*' '<p><div <di </di></di>*</p>'
try 'id_000038_06' '<p>
</>00000' '<p><p>
</>00000</p>'
try 'id_000039_06' '<dl></d>>' '<p><dl></d>></p>'
try 'id_000040_06' '<dl></d
try 'id_000039_06' '<dl></d>>' '<p><dl></d>></p>'
try -ftabstop 'id_000040_06' '<dl></d
>00000' '<p><dl></d
>00000</p>'
try 'id_000043_06' '<dl
>00000</p>'
try 'id_000043_06' '<dl
<</d>>' '<p><dl
<</d>></p>'
try 'id_000048_06' '<dl></d
try 'id_000048_06' '<dl></d
>00000' '<p><dl></d
>00000</p>'
try 'id_000049_06' '<table></tabl>*' '<p><table></tabl>*</p>'
try 'id_000057_06' '<table></tabl>-' '<p><table></tabl>-</p>'
try 'id_000062_06' '<table></tabl>+' '<p><table></tabl>+</p>'
try 'id_000067_06' '<div </di>-' '<p><div </di>-</p>'
try 'id_000072_06' '<ul></u>-' '<p><ul></u>-</p>'
try 'id_000074_06' '<ul></u>>' '<p><ul></u>></p>'
try 'id_000080_06' '<ul
try 'id_000049_06' '<table></tabl>*' '<p><table></tabl>*</p>'
try 'id_000057_06' '<table></tabl>-' '<p><table></tabl>-</p>'
try 'id_000062_06' '<table></tabl>+' '<p><table></tabl>+</p>'
try 'id_000067_06' '<div </di>-' '<p><div </di>-</p>'
try 'id_000072_06' '<ul></u>-' '<p><ul></u>-</p>'
try 'id_000074_06' '<ul></u>>' '<p><ul></u>></p>'
try 'id_000080_06' '<ul
</u>0' '<p><ul
</u>0</p>'
try 'id_000081_06' '<p></
try 'id_000081_06' '<p></
>00000' '<p><p></
>00000</p>'
try 'id_000083_06' '<ul
try 'id_000083_06' '<ul
</u>00000' '<p><ul
</u>00000</p>'
try 'id_000084_06' '<ul></u>*' '<p><ul></u>*</p>'
try 'id_000089_06' '<p></>*' '<p><p></>*</p>'
try 'id_000099_06' '<p></>0.' '<p><p></>0.</p>'
try 'id_000105_06' '<div></di>+' '<p><div></di>+</p>'
try 'id_000108_06' '<p><!--
</>00000' '<p><p>&lt;!&ndash;
</p>'
try 'id_000116_06' '<div></di>0.' '<p><div></di>0.</p>'
try 'id_000119_06' '<div></di
try 'id_000084_06' '<ul></u>*' '<p><ul></u>*</p>'
try 'id_000089_06' '<p></>*' '<p><p></>*</p>'
try 'id_000099_06' '<p></>0.' '<p><p></>0.</p>'
try 'id_000105_06' '<div></di>+' '<p><div></di>+</p>'
try 'id_000108_06' '<p><!--
</>00000' '<p><p><!--
</>00000</p>'
try 'id_000116_06' '<div></di>0.' '<p><div></di>0.</p>'
try 'id_000119_06' '<div></di
>00000' '<p><div></di
>00000</p>'
try 'id_000120_06' '<!-->>' '<p><!-->></p>'
try 'id_000128_06' '<p></>#0' '<p><p></>#0</p>'
try 'id_000130_06' '<blockquote
try 'id_000120_06' '<!-->>' '<p><!-->></p>'
try 'id_000128_06' '<p></>#0' '<p><p></>#0</p>'
try 'id_000130_06' '<blockquote
</blockquot>0' '<p><blockquote
</blockquot>0</p>'
try 'id_000135_06' '<h2></h>>' '<p><h2></h>></p>'
try 'id_000136_06' '<p
try 'id_000135_06' '<h2></h>>' '<p><h2></h>></p>'
try 'id_000136_06' '<p
</>0' '<p><p
</>0</p>'
try 'id_000143_06' '<h2></h>0.' '<p><h2></h>0.</p>'
try 'id_000148_06' '<p
try 'id_000143_06' '<h2></h>0.' '<p><h2></h>0.</p>'
try 'id_000148_06' '<p
</>00000' '<p><p
</>00000</p>'
try 'id_000150_06' '<h2 </h>-' '<p><h2 </h>-</p>'
try 'id_000152_06' '<p></
try 'id_000150_06' '<h2 </h>-' '<p><h2 </h>-</p>'
try -ftabstop 'id_000152_06' '<p></
>00000' '<p><p></
>00000</p>'
try 'id_000153_06' '<p/
>00000</p>'
try 'id_000153_06' '<p/
</>0' '<p><p/
</>0</p>'
try 'id_000158_06' '<div </di>+' '<p><div </di>+</p>'
try 'id_000163_06' '<div></di
try 'id_000158_06' '<div </di>+' '<p><div </di>+</p>'
try -ftabstop 'id_000163_06' '<div></di
>00000' '<p><div></di
>00000</p>'
try 'id_000164_06' '<div></di
>00000</p>'
try 'id_000164_06' '<div></di
>0' '<p><div>&lt;/di</p>
<blockquote><p>0</p></blockquote>'
try 'id_000167_06' '<div </di
try -ftabstop 'id_000167_06' '<div </di
>00000' '<p><div </di
>00000</p>'
try 'id_000173_06' '<dl></d
>00000</p>'
try 'id_000173_06' '<dl></d
>0' '<p><dl>&lt;/d</p>
<blockquote><p>0</p></blockquote>'
try 'id_000174_06' '<dl></d>+' '<p><dl></d>+</p>'
try 'id_000175_06' '<dl></d>=0=
try 'id_000174_06' '<dl></d>+' '<p><dl></d>+</p>'
try 'id_000175_06' '<dl></d>=0=
0' '<p><dl></d>=0=
0</p>'
try 'id_000176_06' '<dl
try 'id_000176_06' '<dl
</d>0' '<p><dl
</d>0</p>'
try 'id_000177_06' '<dl
try 'id_000177_06' '<dl
</d>00000' '<p><dl
</d>00000</p>'
try 'id_000182_06' '<p></>-' '<p><p></>-</p>'
try 'id_000189_06' '<ol></o>#0' '<p><ol></o>#0</p>'
try 'id_000190_06' '<p/</>*' '<p>&lt;p/</>*</p>'
try 'id_000192_06' '<div </di>*' '<p><div </di>*</p>'
try 'id_000197_06' '<ul></u
try 'id_000182_06' '<p></>-' '<p><p></>-</p>'
try 'id_000189_06' '<ol></o>#0' '<p><ol></o>#0</p>'
try 'id_000190_06' '<p/</>*' '<p>&lt;p/</>*</p>'
try 'id_000192_06' '<div </di>*' '<p><div </di>*</p>'
try 'id_000197_06' '<ul></u
>0' '<p><ul>&lt;/u</p>
<blockquote><p>0</p></blockquote>'
try 'id_000201_06' '<ul></u>+' '<p><ul></u>+</p>'
try 'id_000203_06' '<ul></u
try 'id_000201_06' '<ul></u>+' '<p><ul></u>+</p>'
try 'id_000203_06' '<ul></u
>00000' '<p><ul></u
>00000</p>'
try 'id_000209_06' '<!--
try 'id_000209_06' '<!--
-->00000' '<p><!--
-->00000</p>'
try 'id_000211_06' '<p></>+' '<p><p></>+</p>'
try 'id_000219_06' '<!-->*' '<p><!-->*</p>'
try 'id_000222_06' '<p/</>-' '<p>&lt;p/</>-</p>'
try 'id_000223_06' '<!--
try 'id_000211_06' '<p></>+' '<p><p></>+</p>'
try 'id_000219_06' '<!-->*' '<p><!-->*</p>'
try 'id_000222_06' '<p/</>-' '<p>&lt;p/</>-</p>'
try -ftabstop 'id_000223_06' '<!--
-->00000' '<p><!--
-->00000</p>'
try 'id_000224_06' '<!-->0.' '<p><!-->0.</p>'
try 'id_000226_06' '<p>
-->00000</p>'
try 'id_000224_06' '<!-->0.' '<p><!-->0.</p>'
try 'id_000226_06' '<p>
</>0' '<p><p>
</>0</p>'
try 'id_000228_06' '<div></di>*' '<p><div></di>*</p>'
try 'id_000231_06' '<div
try 'id_000228_06' '<div></di>*' '<p><div></di>*</p>'
try 'id_000231_06' '<div
</di>0' '<p><div
</di>0</p>'
try 'id_000238_06' '<p></>[]' '<p><p></>[]</p>'
try 'id_000240_06' '<h2
try 'id_000238_06' '<p></>[]' '<p><p></>[]</p>'
try 'id_000240_06' '<h2
</h>0' '<p><h2
</h>0</p>'
try 'id_000243_06' '<p </>>' '<p><p </>></p>'
try 'id_000246_06' '<p></>>' '<p><p></>></p>'
try 'id_000248_06' '<p </>[]' '<p><p </>[]</p>'
try 'id_000243_06' '<p </>>' '<p><p </>></p>'
try 'id_000246_06' '<p></>>' '<p><p></>></p>'
try 'id_000248_06' '<p </>[]' '<p><p </>[]</p>'
summary $0
exit $rc
......@@ -6,8 +6,5 @@ char markdown_version[] = VERSION
#endif
#if USE_AMALLOC
" DEBUG"
#endif
#if WITH_LATEX
" LATEX"
#endif
;
......@@ -5,14 +5,9 @@
* The redistribution terms are provided in the COPYRIGHT file that must
* be distributed with this source code.
*/
#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include "cstring.h"
#include "markdown.h"
#include "amalloc.h"
#include <markdown.h>
int
......
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