SHA256
1
0
forked from pool/transfig
Dr. Werner Fink 2018-08-30 10:07:54 +00:00 committed by Git OBS Bridge
parent 23cf431efc
commit 56eb478239

View File

@ -129,68 +129,68 @@ https://sourceforge.net/p/mcj/tickets/28.
fread(&header,1,sizeof(struct pcxhed),pcxfile); fread(&header,1,sizeof(struct pcxhed),pcxfile);
if (header.manuf!=10 || header.encod!=1) if (header.manuf!=10 || header.encod!=1)
return 0; return 0;
--- fig2dev/tests/Makefile.am |--- fig2dev/tests/Makefile.am
+++ fig2dev/tests/Makefile.am 2018-08-30 09:47:35.321361539 +0000 |+++ fig2dev/tests/Makefile.am 2018-08-30 09:47:35.321361539 +0000
@@ -40,6 +40,9 @@ $(srcdir)/package.m4: $(top_srcdir)/conf |@@ -40,6 +40,9 @@ $(srcdir)/package.m4: $(top_srcdir)/conf
} >'$(srcdir)/package.m4' | } >'$(srcdir)/package.m4'
|
check_PROGRAMS = test1 | check_PROGRAMS = test1
+# test1 calls malloc(), may be replaced by a rpl_malloc() defined in malloc.o in |+# test1 calls malloc(), may be replaced by a rpl_malloc() defined in malloc.o in
+# LIBOBJS by AC_FUNC_MALLOC in configure.ac |+# LIBOBJS by AC_FUNC_MALLOC in configure.ac
+test1_LDADD = $(LIBOBJS) |+test1_LDADD = $(LIBOBJS)
|
# keep the definition below in sync with that in ../Makefile.am | # keep the definition below in sync with that in ../Makefile.am
AM_CPPFLAGS = -DRGB_FILE="\"$(pkgdatadir)/rgb.txt\"" | AM_CPPFLAGS = -DRGB_FILE="\"$(pkgdatadir)/rgb.txt\""
--- fig2dev/tests/read.at |--- fig2dev/tests/read.at
+++ fig2dev/tests/read.at 2018-08-30 09:47:35.325361467 +0000 |+++ fig2dev/tests/read.at 2018-08-30 09:47:35.325361467 +0000
@@ -208,6 +208,50 @@ EOF |@@ -208,6 +208,50 @@ EOF
],1,ignore,ignore) | ],1,ignore,ignore)
AT_CLEANUP | AT_CLEANUP
|
+AT_SETUP([correctly free invalid spline, ticket #27]) |+AT_SETUP([correctly free invalid spline, ticket #27])
+AT_KEYWORDS([read.c]) |+AT_KEYWORDS([read.c])
+AT_CHECK([fig2dev -L box <<EOF |+AT_CHECK([fig2dev -L box <<EOF
+#FIG 2 |+#FIG 2
+1200 2 |+1200 2
+3 0 0 0 0 0 0 0 0. 0 1 |+3 0 0 0 0 0 0 0 0. 0 1
+0 |+0
+EOF |+EOF
+],1,ignore,[Incomplete spline object at line 3. |+],1,ignore,[Incomplete spline object at line 3.
+]) |+])
+AT_CLEANUP |+AT_CLEANUP
+ |+
+AT_SETUP([allow last line without newline, ticket #28]) |+AT_SETUP([allow last line without newline, ticket #28])
+AT_KEYWORDS([read.c]) |+AT_KEYWORDS([read.c])
+AT_CHECK([AS_ECHO_N(['#FIG 2 |+AT_CHECK([AS_ECHO_N(['#FIG 2
+0']) | fig2dev -L box], |+0']) | fig2dev -L box],
+1, ignore, [Incomplete resolution information at line 1. |+1, ignore, [Incomplete resolution information at line 1.
+]) |+])
+AT_CLEANUP |+AT_CLEANUP
+ |+
+AT_SETUP([correctly free invalid line object]) |+AT_SETUP([correctly free invalid line object])
+AT_KEYWORDS([read.c]) |+AT_KEYWORDS([read.c])
+AT_CHECK([fig2dev -L box <<EOF |+AT_CHECK([fig2dev -L box <<EOF
+#FIG 2 |+#FIG 2
+1200 2 |+1200 2
+2 1 1 1 -1 50 0 0 0. 0 0 |+2 1 1 1 -1 50 0 0 0. 0 0
+0 |+0
+EOF |+EOF
+], 1, ignore, [Incomplete line object at line 3. |+], 1, ignore, [Incomplete line object at line 3.
+]) |+])
+AT_CLEANUP |+AT_CLEANUP
+ |+
+AT_SETUP([correctly free invalid line with picture]) |+AT_SETUP([correctly free invalid line with picture])
+AT_KEYWORDS([read.c]) |+AT_KEYWORDS([read.c])
+AT_CHECK([fig2dev -L box <<EOF |+AT_CHECK([fig2dev -L box <<EOF
+FIG_FILE_TOP |+FIG_FILE_TOP
+2 5 0 1 0 -1 50 0 0 0. 0 0 0 0 0 5 |+2 5 0 1 0 -1 50 0 0 0. 0 0 0 0 0 5
+0 img |+0 img
+0 |+0
+EOF |+EOF
+], 1, ignore, [Incomplete line object at line 12. |+], 1, ignore, [Incomplete line object at line 12.
+]) |+])
+AT_CLEANUP |+AT_CLEANUP
+ |+
AT_BANNER([Dynamically allocate picture file name.]) | AT_BANNER([Dynamically allocate picture file name.])
|
AT_SETUP([prepend fig file path to picture file name]) | AT_SETUP([prepend fig file path to picture file name])