diff options
Diffstat (limited to 'Build/source/libs/potrace')
-rw-r--r-- | Build/source/libs/potrace/ChangeLog | 6 | ||||
-rwxr-xr-x | Build/source/libs/potrace/configure | 24 | ||||
-rw-r--r-- | Build/source/libs/potrace/configure.ac | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src-PATCHES/ChangeLog (renamed from Build/source/libs/potrace/potrace-1.12-PATCHES/ChangeLog) | 6 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src-PATCHES/TL-Changes (renamed from Build/source/libs/potrace/potrace-1.12-PATCHES/TL-Changes) | 3 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/AUTHORS (renamed from Build/source/libs/potrace/potrace-1.12/AUTHORS) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/ChangeLog (renamed from Build/source/libs/potrace/potrace-1.12/ChangeLog) | 14 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/Makefile.am (renamed from Build/source/libs/potrace/potrace-1.12/Makefile.am) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/NEWS (renamed from Build/source/libs/potrace/potrace-1.12/NEWS) | 10 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/README (renamed from Build/source/libs/potrace/potrace-1.12/README) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/README-WIN (renamed from Build/source/libs/potrace/potrace-1.12/README-WIN) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/config.h.in (renamed from Build/source/libs/potrace/potrace-1.12/config.h.in) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/configure.ac (renamed from Build/source/libs/potrace/potrace-1.12/configure.ac) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/Makefile.am (renamed from Build/source/libs/potrace/potrace-1.12/src/Makefile.am) | 2 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/auxiliary.h (renamed from Build/source/libs/potrace/potrace-1.12/src/auxiliary.h) | 6 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_dxf.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_dxf.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_dxf.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_dxf.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_eps.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_eps.c) | 10 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_eps.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_eps.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_geojson.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_geojson.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_geojson.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_geojson.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_pdf.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_pdf.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_pdf.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_pdf.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_pgm.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_pgm.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_pgm.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_pgm.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_svg.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_svg.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_svg.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_svg.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_xfig.c (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_xfig.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/backend_xfig.h (renamed from Build/source/libs/potrace/potrace-1.12/src/backend_xfig.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bbox.c (renamed from Build/source/libs/potrace/potrace-1.12/src/bbox.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bbox.h (renamed from Build/source/libs/potrace/potrace-1.12/src/bbox.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bitmap.h (renamed from Build/source/libs/potrace/potrace-1.12/src/bitmap.h) | 17 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bitmap_io.c (renamed from Build/source/libs/potrace/potrace-1.12/src/bitmap_io.c) | 28 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bitmap_io.h (renamed from Build/source/libs/potrace/potrace-1.12/src/bitmap_io.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/bitops.h (renamed from Build/source/libs/potrace/potrace-1.12/src/bitops.h) | 2 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/curve.c (renamed from Build/source/libs/potrace/potrace-1.12/src/curve.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/curve.h (renamed from Build/source/libs/potrace/potrace-1.12/src/curve.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/decompose.c (renamed from Build/source/libs/potrace/potrace-1.12/src/decompose.c) | 3 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/decompose.h (renamed from Build/source/libs/potrace/potrace-1.12/src/decompose.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/flate.c (renamed from Build/source/libs/potrace/potrace-1.12/src/flate.c) | 2 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/flate.h (renamed from Build/source/libs/potrace/potrace-1.12/src/flate.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/getopt.c (renamed from Build/source/libs/potrace/potrace-1.12/src/getopt.c) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/getopt.h (renamed from Build/source/libs/potrace/potrace-1.12/src/getopt.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/getopt1.c (renamed from Build/source/libs/potrace/potrace-1.12/src/getopt1.c) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/greymap.c (renamed from Build/source/libs/potrace/potrace-1.12/src/greymap.c) | 7 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/greymap.h (renamed from Build/source/libs/potrace/potrace-1.12/src/greymap.h) | 3 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/libpotrace-export.sym (renamed from Build/source/libs/potrace/potrace-1.12/src/libpotrace-export.sym) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/lists.h (renamed from Build/source/libs/potrace/potrace-1.12/src/lists.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/lzw.c (renamed from Build/source/libs/potrace/potrace-1.12/src/lzw.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/lzw.h (renamed from Build/source/libs/potrace/potrace-1.12/src/lzw.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/main.c (renamed from Build/source/libs/potrace/potrace-1.12/src/main.c) | 10 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/main.h (renamed from Build/source/libs/potrace/potrace-1.12/src/main.h) | 2 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/mkbitmap.c (renamed from Build/source/libs/potrace/potrace-1.12/src/mkbitmap.c) | 10 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/platform.h (renamed from Build/source/libs/potrace/potrace-1.12/src/platform.h) | 2 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/potracelib.c (renamed from Build/source/libs/potrace/potrace-1.12/src/potracelib.c) | 8 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/potracelib.h (renamed from Build/source/libs/potrace/potrace-1.12/src/potracelib.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/potracelib_demo.c (renamed from Build/source/libs/potrace/potrace-1.12/src/potracelib_demo.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/progress.h (renamed from Build/source/libs/potrace/potrace-1.12/src/progress.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/progress_bar.c (renamed from Build/source/libs/potrace/potrace-1.12/src/progress_bar.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/progress_bar.h (renamed from Build/source/libs/potrace/potrace-1.12/src/progress_bar.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/render.c (renamed from Build/source/libs/potrace/potrace-1.12/src/render.c) | 3 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/render.h (renamed from Build/source/libs/potrace/potrace-1.12/src/render.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/trace.c (renamed from Build/source/libs/potrace/potrace-1.12/src/trace.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/trace.h (renamed from Build/source/libs/potrace/potrace-1.12/src/trace.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/trans.c (renamed from Build/source/libs/potrace/potrace-1.12/src/trans.c) | 4 | ||||
-rw-r--r-- | Build/source/libs/potrace/potrace-src/src/trans.h (renamed from Build/source/libs/potrace/potrace-1.12/src/trans.h) | 0 | ||||
-rw-r--r-- | Build/source/libs/potrace/version.ac | 2 |
67 files changed, 178 insertions, 86 deletions
diff --git a/Build/source/libs/potrace/ChangeLog b/Build/source/libs/potrace/ChangeLog index 38f1355a7a6..a896d1709ea 100644 --- a/Build/source/libs/potrace/ChangeLog +++ b/Build/source/libs/potrace/ChangeLog @@ -1,3 +1,9 @@ +2015-12-28 Akira Kakuto <kakuto@fuk.kindai.ac.jp> + + Import potrace-1.13. + * configure.ac: New source-tree-naming convention per Karl. + * version.ac: Adjust. + 2015-07-06 Peter Breitenlohner <peb@mppmu.mpg.de> * Makefile.am: Better dependencies for 'make check'. diff --git a/Build/source/libs/potrace/configure b/Build/source/libs/potrace/configure index 64ddcb85974..a48a133aac7 100755 --- a/Build/source/libs/potrace/configure +++ b/Build/source/libs/potrace/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for potrace (TeX Live) 1.12. +# Generated by GNU Autoconf 2.69 for potrace (TeX Live) 1.13. # # Report bugs to <tex-k@tug.org>. # @@ -580,12 +580,12 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='potrace (TeX Live)' PACKAGE_TARNAME='potrace--tex-live-' -PACKAGE_VERSION='1.12' -PACKAGE_STRING='potrace (TeX Live) 1.12' +PACKAGE_VERSION='1.13' +PACKAGE_STRING='potrace (TeX Live) 1.13' PACKAGE_BUGREPORT='tex-k@tug.org' PACKAGE_URL='' -ac_unique_file="potrace-1.12/src/trace.c" +ac_unique_file="potrace-src/src/trace.c" ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS @@ -1241,7 +1241,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures potrace (TeX Live) 1.12 to adapt to many kinds of systems. +\`configure' configures potrace (TeX Live) 1.13 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1308,7 +1308,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of potrace (TeX Live) 1.12:";; + short | recursive ) echo "Configuration of potrace (TeX Live) 1.13:";; esac cat <<\_ACEOF @@ -1405,7 +1405,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -potrace (TeX Live) configure 1.12 +potrace (TeX Live) configure 1.13 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -1585,7 +1585,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by potrace (TeX Live) $as_me 1.12, which was +It was created by potrace (TeX Live) $as_me 1.13, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3508,7 +3508,7 @@ fi # Define the identity of the package. PACKAGE='potrace--tex-live-' - VERSION='1.12' + VERSION='1.13' cat >>confdefs.h <<_ACEOF @@ -5034,7 +5034,7 @@ if test "$ac_res" != no; then : fi -POTRACE_TREE=potrace-1.12 +POTRACE_TREE=potrace-src ac_config_files="$ac_config_files Makefile include/Makefile" @@ -5582,7 +5582,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by potrace (TeX Live) $as_me 1.12, which was +This file was extended by potrace (TeX Live) $as_me 1.13, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -5648,7 +5648,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -potrace (TeX Live) config.status 1.12 +potrace (TeX Live) config.status 1.13 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff --git a/Build/source/libs/potrace/configure.ac b/Build/source/libs/potrace/configure.ac index 272a612d379..378b290f74e 100644 --- a/Build/source/libs/potrace/configure.ac +++ b/Build/source/libs/potrace/configure.ac @@ -9,7 +9,7 @@ dnl m4_include([version.ac])[] dnl define potrace_version AC_INIT([potrace (TeX Live)], potrace_version, [tex-k@tug.org]) AC_PREREQ([2.65]) -AC_CONFIG_SRCDIR([potrace-]potrace_version[/src/trace.c]) +AC_CONFIG_SRCDIR([potrace-src/src/trace.c]) AC_CONFIG_AUX_DIR([../../build-aux]) AC_CONFIG_MACRO_DIR([../../m4]) @@ -31,7 +31,7 @@ fi AC_SEARCH_LIBS([sqrt], [m]) -AC_SUBST([POTRACE_TREE], [potrace-]potrace_version) +AC_SUBST([POTRACE_TREE], [potrace-src]) AC_CONFIG_FILES([Makefile include/Makefile]) diff --git a/Build/source/libs/potrace/potrace-1.12-PATCHES/ChangeLog b/Build/source/libs/potrace/potrace-src-PATCHES/ChangeLog index bc586d15581..b006f21b545 100644 --- a/Build/source/libs/potrace/potrace-1.12-PATCHES/ChangeLog +++ b/Build/source/libs/potrace/potrace-src-PATCHES/ChangeLog @@ -1,3 +1,8 @@ +2015-12-28 Akira Kakuto <kakuto@fuk.kindai.ac.jp> + + Import potrace-1.13 source tree from: + http://potrace.sourceforge.net + 2015-03-27 Peter Breitenlohner <peb@mppmu.mpg.de> Import potrace-1.12 source tree from: @@ -7,4 +12,3 @@ Import potrace-1.11 source tree from: http://potrace.sourceforge.net - diff --git a/Build/source/libs/potrace/potrace-1.12-PATCHES/TL-Changes b/Build/source/libs/potrace/potrace-src-PATCHES/TL-Changes index b6a24551c89..5eeb6e10376 100644 --- a/Build/source/libs/potrace/potrace-1.12-PATCHES/TL-Changes +++ b/Build/source/libs/potrace/potrace-src-PATCHES/TL-Changes @@ -1,4 +1,4 @@ -Changes applied to the potrace-1.12/ tree as obtained from: +Changes applied to the potrace-1.13/ tree as obtained from: http://potrace.sourceforge.net Removed: @@ -20,4 +20,3 @@ Removed: mkinstalldirs src/Makefile.in test-driver - diff --git a/Build/source/libs/potrace/potrace-1.12/AUTHORS b/Build/source/libs/potrace/potrace-src/AUTHORS index f6b22007218..f6b22007218 100644 --- a/Build/source/libs/potrace/potrace-1.12/AUTHORS +++ b/Build/source/libs/potrace/potrace-src/AUTHORS diff --git a/Build/source/libs/potrace/potrace-1.12/ChangeLog b/Build/source/libs/potrace/potrace-src/ChangeLog index 616d42f83f3..afee2358ed8 100644 --- a/Build/source/libs/potrace/potrace-1.12/ChangeLog +++ b/Build/source/libs/potrace/potrace-src/ChangeLog @@ -1,5 +1,19 @@ ChangeLog +v1.13 2015/10/22 + (2015/07/18) PS1 - fixed heap overflows, null pointer dereference + bugs and a memory leak. Reported by Agostino Sarubbo. + (2015/05/17) PS1 - man page: show which backends are dimension + based, and state more clearly that svg backend defaults to 72dpi. + (2015/04/11) PS1 - portability: ssize_t not supported on some + systems; use ptrdiff_t instead. Reported by Martin Gieseking. + (2015/03/28) PS1 - portability: added missing #includes for c99, + reported by Nelson Beebe. + (2015/03/27) PS1 - include config.h before other header files, + reported by Peter Breitenlohner. + (2015/03/26) PS1 - fixed division by zero bug triggered by bitmap + of dimension 1x0. Reported by Tomasz Buchert. + v1.12 2015/03/24 (2015/03/20) PS1 - fixed memory overflow bug triggered by very large bitmaps. Fixes RedHat bug #955808 reported by Vincent Danen diff --git a/Build/source/libs/potrace/potrace-1.12/Makefile.am b/Build/source/libs/potrace/potrace-src/Makefile.am index f6a17faf852..f6a17faf852 100644 --- a/Build/source/libs/potrace/potrace-1.12/Makefile.am +++ b/Build/source/libs/potrace/potrace-src/Makefile.am diff --git a/Build/source/libs/potrace/potrace-1.12/NEWS b/Build/source/libs/potrace/potrace-src/NEWS index 9e311bbaee0..6571a44ece2 100644 --- a/Build/source/libs/potrace/potrace-1.12/NEWS +++ b/Build/source/libs/potrace/potrace-src/NEWS @@ -1,3 +1,13 @@ +October 22, 2015: Release 1.13 + + Some critical bugs in the processing of BMP files were fixed. These + bugs allowed the program to be crashed, or potentially to be abused + in other ways, by feeding it specially crafted BMP files. Thanks to + Tomasz Buchert and Agostino Sarubbo for reporting these bugs. + Portability was improved for C99 and for MSVC++. Thanks to Peter + Breitenlohner, Nelson Beebe, and Martin Gieseking for reporting + portability issues. + March 24, 2015: Release 1.12 Fixed memory overflow bug triggered by very large bitmaps. Fixed diff --git a/Build/source/libs/potrace/potrace-1.12/README b/Build/source/libs/potrace/potrace-src/README index b29197ea0e1..b29197ea0e1 100644 --- a/Build/source/libs/potrace/potrace-1.12/README +++ b/Build/source/libs/potrace/potrace-src/README diff --git a/Build/source/libs/potrace/potrace-1.12/README-WIN b/Build/source/libs/potrace/potrace-src/README-WIN index ff16913c8ee..ff16913c8ee 100644 --- a/Build/source/libs/potrace/potrace-1.12/README-WIN +++ b/Build/source/libs/potrace/potrace-src/README-WIN diff --git a/Build/source/libs/potrace/potrace-1.12/config.h.in b/Build/source/libs/potrace/potrace-src/config.h.in index 6dea9accfa9..6dea9accfa9 100644 --- a/Build/source/libs/potrace/potrace-1.12/config.h.in +++ b/Build/source/libs/potrace/potrace-src/config.h.in diff --git a/Build/source/libs/potrace/potrace-1.12/configure.ac b/Build/source/libs/potrace/potrace-src/configure.ac index b0ecb2a18d7..93be9b1c00d 100644 --- a/Build/source/libs/potrace/potrace-1.12/configure.ac +++ b/Build/source/libs/potrace/potrace-src/configure.ac @@ -6,13 +6,13 @@ dnl Process this file with autoconf to produce a configure script. dnl ---------------------------------------------------------------------- dnl Package info -AC_INIT([potrace],[1.12],[selinger at users.sourceforge.net]) +AC_INIT([potrace],[1.13],[selinger at users.sourceforge.net]) AC_CONFIG_SRCDIR(src/trace.c) AM_INIT_AUTOMAKE AC_CONFIG_HEADER(config.h) AC_CONFIG_MACRO_DIR([m4]) -DATE="March 2015" +DATE="October 2015" dnl ---------------------------------------------------------------------- dnl The names of the installed executables are defined here, but diff --git a/Build/source/libs/potrace/potrace-1.12/src/Makefile.am b/Build/source/libs/potrace/potrace-src/src/Makefile.am index bd12591ed24..bf8431223b4 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/Makefile.am +++ b/Build/source/libs/potrace/potrace-src/src/Makefile.am @@ -42,7 +42,7 @@ libsources = curve.c curve.h trace.c trace.h decompose.c \ lib_LTLIBRARIES = $(INSTLIBS) EXTRA_LTLIBRARIES = libpotrace.la libpotrace_la_SOURCES = $(libsources) -libpotrace_la_LDFLAGS = -version-info 0:2:0 -rpath '$(libdir)' \ +libpotrace_la_LDFLAGS = -version-info 0:3:0 -rpath '$(libdir)' \ -export-symbols $(srcdir)/libpotrace-export.sym -no-undefined libpotrace_la_LIBADD = -lm MOSTLYCLEANFILES = libpotrace.la diff --git a/Build/source/libs/potrace/potrace-1.12/src/auxiliary.h b/Build/source/libs/potrace/potrace-src/src/auxiliary.h index dbf124d7c2b..b365a0b402b 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/auxiliary.h +++ b/Build/source/libs/potrace/potrace-src/src/auxiliary.h @@ -8,12 +8,12 @@ #ifndef AUXILIARY_H #define AUXILIARY_H -#include <stdlib.h> - #ifdef HAVE_CONFIG_H -#include "config.h" +#include <config.h> #endif +#include <stdlib.h> + /* ---------------------------------------------------------------------- */ /* point arithmetic */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_dxf.c b/Build/source/libs/potrace/potrace-src/src/backend_dxf.c index 938afde38be..39b12a9d76f 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_dxf.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_dxf.c @@ -4,6 +4,10 @@ /* The DXF backend of Potrace. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -16,10 +20,6 @@ #include "auxiliary.h" #include "trans.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #ifndef M_PI #define M_PI 3.14159265358979323846 #endif diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_dxf.h b/Build/source/libs/potrace/potrace-src/src/backend_dxf.h index 37906a0eaf3..37906a0eaf3 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_dxf.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_dxf.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_eps.c b/Build/source/libs/potrace/potrace-src/src/backend_eps.c index 6ea50694813..d992a1a2cf8 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_eps.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_eps.c @@ -8,6 +8,12 @@ output. Postscript compression is optionally supplied via the functions in flate.c. */ +#define _XOPEN_SOURCE 500 + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -22,10 +28,6 @@ #include "lists.h" #include "auxiliary.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #define SAFE_CALLOC(var, n, typ) \ if ((var = (typ *)calloc(n, sizeof(typ))) == NULL) goto calloc_error diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_eps.h b/Build/source/libs/potrace/potrace-src/src/backend_eps.h index 90c866622cb..90c866622cb 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_eps.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_eps.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_geojson.c b/Build/source/libs/potrace/potrace-src/src/backend_geojson.c index ff3082bcc88..d5318581f11 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_geojson.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_geojson.c @@ -5,6 +5,10 @@ /* The GeoJSON backend of Potrace. */ /* Written 2012 by Christoph Hormann <chris_hormann@gmx.de> */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -17,10 +21,6 @@ #include "lists.h" #include "auxiliary.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - /* ---------------------------------------------------------------------- */ /* auxiliary */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_geojson.h b/Build/source/libs/potrace/potrace-src/src/backend_geojson.h index 985cc3c919e..985cc3c919e 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_geojson.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_geojson.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_pdf.c b/Build/source/libs/potrace/potrace-src/src/backend_pdf.c index 10446b68e32..f350557a853 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_pdf.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_pdf.c @@ -6,6 +6,10 @@ /* The PDF backend of Potrace. Stream compression is optionally supplied via the functions in flate.c. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -19,10 +23,6 @@ #include "potracelib.h" #include "auxiliary.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - typedef int color_t; /* ---------------------------------------------------------------------- */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_pdf.h b/Build/source/libs/potrace/potrace-src/src/backend_pdf.h index 3bad72d4755..3bad72d4755 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_pdf.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_pdf.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_pgm.c b/Build/source/libs/potrace/potrace-src/src/backend_pgm.c index 8e1b94e063b..f6714258360 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_pgm.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_pgm.c @@ -8,6 +8,10 @@ convenience, as the same could be achieved by piping the EPS output through ghostscript. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <math.h> #include "backend_pgm.h" @@ -19,10 +23,6 @@ #include "auxiliary.h" #include "trans.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #ifndef M_PI #define M_PI 3.14159265358979323846 #endif diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_pgm.h b/Build/source/libs/potrace/potrace-src/src/backend_pgm.h index 499e925b425..499e925b425 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_pgm.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_pgm.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_svg.c b/Build/source/libs/potrace/potrace-src/src/backend_svg.c index fd30eda4eb4..4dd67c8934c 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_svg.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_svg.c @@ -5,6 +5,10 @@ /* The SVG backend of Potrace. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -17,10 +21,6 @@ #include "lists.h" #include "auxiliary.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - /* ---------------------------------------------------------------------- */ /* path-drawing auxiliary functions */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_svg.h b/Build/source/libs/potrace/potrace-src/src/backend_svg.h index 0bacb1c939e..0bacb1c939e 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_svg.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_svg.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_xfig.c b/Build/source/libs/potrace/potrace-src/src/backend_xfig.c index e51d1dcafc3..a4d2947229b 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_xfig.c +++ b/Build/source/libs/potrace/potrace-src/src/backend_xfig.c @@ -5,6 +5,10 @@ /* The xfig backend of Potrace. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdarg.h> #include <string.h> @@ -17,10 +21,6 @@ #include "auxiliary.h" #include "trans.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #ifndef M_PI #define M_PI 3.14159265358979323846 #endif diff --git a/Build/source/libs/potrace/potrace-1.12/src/backend_xfig.h b/Build/source/libs/potrace/potrace-src/src/backend_xfig.h index b1d3af2b14e..b1d3af2b14e 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/backend_xfig.h +++ b/Build/source/libs/potrace/potrace-src/src/backend_xfig.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/bbox.c b/Build/source/libs/potrace/potrace-src/src/bbox.c index 8deb7605974..27b16ebcb79 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bbox.c +++ b/Build/source/libs/potrace/potrace-src/src/bbox.c @@ -4,6 +4,10 @@ /* figure out the true bounding box of a vector image */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <math.h> #include <stdlib.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/bbox.h b/Build/source/libs/potrace/potrace-src/src/bbox.h index 12e74626462..12e74626462 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bbox.h +++ b/Build/source/libs/potrace/potrace-src/src/bbox.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/bitmap.h b/Build/source/libs/potrace/potrace-src/src/bitmap.h index 086bbb0467d..7b5a94bb161 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bitmap.h +++ b/Build/source/libs/potrace/potrace-src/src/bitmap.h @@ -8,6 +8,7 @@ #include <string.h> #include <stdlib.h> #include <errno.h> +#include <stddef.h> /* The bitmap type is defined in potracelib.h */ #include "potracelib.h" @@ -28,7 +29,7 @@ /* macros for accessing pixel at index (x,y). U* macros omit the bounds check. */ -#define bm_scanline(bm, y) ((bm)->map + (ssize_t)(y)*(ssize_t)(bm)->dy) +#define bm_scanline(bm, y) ((bm)->map + (ptrdiff_t)(y)*(ptrdiff_t)(bm)->dy) #define bm_index(bm, x, y) (&bm_scanline(bm, y)[(x)/BM_WORDBITS]) #define bm_mask(x) (BM_HIBIT >> ((x) & (BM_WORDBITS-1))) #define bm_range(x, a) ((int)(x) >= 0 && (int)(x) < (a)) @@ -57,10 +58,10 @@ static inline void bm_free(potrace_bitmap_t *bm) { static inline potrace_bitmap_t *bm_new(int w, int h) { potrace_bitmap_t *bm; int dy = w == 0 ? 0 : (w - 1) / BM_WORDBITS + 1; - ssize_t size = (ssize_t)dy * (ssize_t)h * (ssize_t)BM_WORDSIZE; + ptrdiff_t size = (ptrdiff_t)dy * (ptrdiff_t)h * (ptrdiff_t)BM_WORDSIZE; /* check for overflow error */ - if (size < 0 || size / h / dy != BM_WORDSIZE) { + if (size < 0 || (h != 0 && dy != 0 && size / h / dy != BM_WORDSIZE)) { errno = ENOMEM; return NULL; } @@ -83,15 +84,15 @@ static inline potrace_bitmap_t *bm_new(int w, int h) { /* clear the given bitmap. Set all bits to c. */ static inline void bm_clear(potrace_bitmap_t *bm, int c) { /* Note: if the bitmap was created with bm_new, then it is - guaranteed that size will fit into the ssize_t type. */ - ssize_t size = (ssize_t)bm->dy * (ssize_t)bm->h * (ssize_t)BM_WORDSIZE; + guaranteed that size will fit into the ptrdiff_t type. */ + ptrdiff_t size = (ptrdiff_t)bm->dy * (ptrdiff_t)bm->h * (ptrdiff_t)BM_WORDSIZE; memset(bm->map, c ? -1 : 0, size); } /* duplicate the given bitmap. Return NULL on error with errno set. */ static inline potrace_bitmap_t *bm_dup(const potrace_bitmap_t *bm) { potrace_bitmap_t *bm1 = bm_new(bm->w, bm->h); - ssize_t size = (ssize_t)bm->dy * (ssize_t)bm->h * (ssize_t)BM_WORDSIZE; + ptrdiff_t size = (ptrdiff_t)bm->dy * (ptrdiff_t)bm->h * (ptrdiff_t)BM_WORDSIZE; if (!bm1) { return NULL; } @@ -101,8 +102,8 @@ static inline potrace_bitmap_t *bm_dup(const potrace_bitmap_t *bm) { /* invert the given bitmap. */ static inline void bm_invert(potrace_bitmap_t *bm) { - ssize_t i; - ssize_t size = (ssize_t)bm->dy * (ssize_t)bm->h; + ptrdiff_t i; + ptrdiff_t size = (ptrdiff_t)bm->dy * (ptrdiff_t)bm->h; for (i = 0; i < size; i++) { bm->map[i] ^= BM_ALLBITS; diff --git a/Build/source/libs/potrace/potrace-1.12/src/bitmap_io.c b/Build/source/libs/potrace/potrace-src/src/bitmap_io.c index 5b70c7cebf7..8bbfe2dcdaa 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bitmap_io.c +++ b/Build/source/libs/potrace/potrace-src/src/bitmap_io.c @@ -5,6 +5,10 @@ /* Routines for manipulating bitmaps, including reading pbm files. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include "bitmap.h" @@ -424,6 +428,9 @@ static int bmp_forward(FILE *f, int pos) { /* correct y-coordinate for top-down format */ #define ycorr(y) (bmpinfo.topdown ? bmpinfo.h-1-y : y) +/* safe colortable access */ +#define COLTABLE(c) ((c) < bmpinfo.ncolors ? coltable[(c)] : 0) + /* read BMP stream after magic number. Return values as for bm_read. We choose to be as permissive as possible, since there are many programs out there which produce BMP. For instance, ppmtobmp can @@ -509,6 +516,10 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { goto format_error; } + if (bmpinfo.comp > 3 || bmpinfo.bits > 32) { + goto format_error; + } + /* forward to color table (e.g., if bmpinfo.InfoSize == 64) */ TRY(bmp_forward(f, 14+bmpinfo.InfoSize)); @@ -598,7 +609,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { b = bitbuf >> (INTBITS - bmpinfo.bits); bitbuf <<= bmpinfo.bits; n -= bmpinfo.bits; - BM_UPUT(bm, x, ycorr(y), coltable[b]); + BM_UPUT(bm, x, ycorr(y), COLTABLE(b)); } TRY(bmp_pad(f)); } @@ -643,13 +654,14 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { case 0x204: /* 4-bit runlength compressed encoding (RLE4) */ x = 0; y = 0; + while (1) { TRY_EOF(bmp_readint(f, 1, &b)); /* opcode */ TRY_EOF(bmp_readint(f, 1, &c)); /* argument */ if (b>0) { /* repeat count */ - col[0] = coltable[(c>>4) & 0xf]; - col[1] = coltable[c & 0xf]; + col[0] = COLTABLE((c>>4) & 0xf); + col[1] = COLTABLE(c & 0xf); for (i=0; i<b && x<bmpinfo.w; i++) { if (x>=bmpinfo.w) { x=0; @@ -687,7 +699,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { if (y>=bmpinfo.h) { break; } - BM_PUT(bm, x, ycorr(y), coltable[(b>>(4-4*(i&1))) & 0xf]); + BM_PUT(bm, x, ycorr(y), COLTABLE((b>>(4-4*(i&1))) & 0xf)); x++; } if ((c+1) & 2) { @@ -714,7 +726,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { if (y>=bmpinfo.h) { break; } - BM_UPUT(bm, x, ycorr(y), coltable[c]); + BM_UPUT(bm, x, ycorr(y), COLTABLE(c)); x++; } } else if (c == 0) { @@ -741,7 +753,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { if (y>=bmpinfo.h) { break; } - BM_PUT(bm, x, ycorr(y), coltable[b]); + BM_PUT(bm, x, ycorr(y), COLTABLE(b)); x++; } if (c & 1) { @@ -770,7 +782,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { format_error: try_error: free(coltable); - free(bm); + bm_free(bm); if (!bm_read_error) { bm_read_error = "invalid bmp file"; } @@ -778,7 +790,7 @@ static int bm_readbody_bmp(FILE *f, double threshold, potrace_bitmap_t **bmp) { std_error: free(coltable); - free(bm); + bm_free(bm); return -1; } diff --git a/Build/source/libs/potrace/potrace-1.12/src/bitmap_io.h b/Build/source/libs/potrace/potrace-src/src/bitmap_io.h index 04b1c9ca1d2..04b1c9ca1d2 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bitmap_io.h +++ b/Build/source/libs/potrace/potrace-src/src/bitmap_io.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/bitops.h b/Build/source/libs/potrace/potrace-src/src/bitops.h index cff734a4615..ba84b53269b 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/bitops.h +++ b/Build/source/libs/potrace/potrace-src/src/bitops.h @@ -16,7 +16,7 @@ #define BITOPS_H #ifdef HAVE_CONFIG_H -#include "config.h" +#include <config.h> #endif /* ---------------------------------------------------------------------- */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/curve.c b/Build/source/libs/potrace/potrace-src/src/curve.c index e6a9a47219e..d782f22ea65 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/curve.c +++ b/Build/source/libs/potrace/potrace-src/src/curve.c @@ -4,6 +4,10 @@ /* private part of the path and curve data structures */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <stdlib.h> #include <string.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/curve.h b/Build/source/libs/potrace/potrace-src/src/curve.h index feb95b39b49..feb95b39b49 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/curve.h +++ b/Build/source/libs/potrace/potrace-src/src/curve.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/decompose.c b/Build/source/libs/potrace/potrace-src/src/decompose.c index bfc6772a6b8..26126377ad8 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/decompose.c +++ b/Build/source/libs/potrace/potrace-src/src/decompose.c @@ -2,6 +2,9 @@ This file is part of Potrace. It is free software and it is covered by the GNU General Public License. See the file COPYING for details. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif #include <stdio.h> #include <stdlib.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/decompose.h b/Build/source/libs/potrace/potrace-src/src/decompose.h index 8ae89b8adc3..8ae89b8adc3 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/decompose.h +++ b/Build/source/libs/potrace/potrace-src/src/decompose.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/flate.c b/Build/source/libs/potrace/potrace-src/src/flate.c index 9e1e7232dd7..9965d15d3f0 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/flate.c +++ b/Build/source/libs/potrace/potrace-src/src/flate.c @@ -23,7 +23,7 @@ reentrant */ #ifdef HAVE_CONFIG_H -#include "config.h" +#include <config.h> #endif #include <stdio.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/flate.h b/Build/source/libs/potrace/potrace-src/src/flate.h index 7b51245503d..7b51245503d 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/flate.h +++ b/Build/source/libs/potrace/potrace-src/src/flate.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/getopt.c b/Build/source/libs/potrace/potrace-src/src/getopt.c index 0c8fdd11bb3..0c8fdd11bb3 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/getopt.c +++ b/Build/source/libs/potrace/potrace-src/src/getopt.c diff --git a/Build/source/libs/potrace/potrace-1.12/src/getopt.h b/Build/source/libs/potrace/potrace-src/src/getopt.h index 20daef6168b..20daef6168b 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/getopt.h +++ b/Build/source/libs/potrace/potrace-src/src/getopt.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/getopt1.c b/Build/source/libs/potrace/potrace-src/src/getopt1.c index 8ffe0e6ad71..8ffe0e6ad71 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/getopt1.c +++ b/Build/source/libs/potrace/potrace-src/src/getopt1.c diff --git a/Build/source/libs/potrace/potrace-1.12/src/greymap.c b/Build/source/libs/potrace/potrace-src/src/greymap.c index f5bad69ae39..ad8e5d7e303 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/greymap.c +++ b/Build/source/libs/potrace/potrace-src/src/greymap.c @@ -6,10 +6,15 @@ /* Routines for manipulating greymaps, including reading pgm files. We only deal with greymaps of depth 8 bits. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdlib.h> #include <string.h> #include <math.h> #include <errno.h> +#include <stddef.h> #include "greymap.h" #include "bitops.h" @@ -28,7 +33,7 @@ static int gm_readbody_bmp(FILE *f, greymap_t **gmp); Assumes w, h >= 0. */ greymap_t *gm_new(int w, int h) { greymap_t *gm; - ssize_t size = (ssize_t)w * (ssize_t)h * (ssize_t)sizeof(signed short int); + ptrdiff_t size = (ptrdiff_t)w * (ptrdiff_t)h * (ptrdiff_t)sizeof(signed short int); /* check for overflow error */ if (size < 0 || size / w / h != sizeof(signed short int)) { diff --git a/Build/source/libs/potrace/potrace-1.12/src/greymap.h b/Build/source/libs/potrace/potrace-src/src/greymap.h index 390f17fbb8d..7a5011ab8f8 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/greymap.h +++ b/Build/source/libs/potrace/potrace-src/src/greymap.h @@ -8,6 +8,7 @@ #include <stdio.h> #include <stdlib.h> +#include <stddef.h> /* internal format for greymaps. Note: in this format, rows are ordered from bottom to top. The pixels in each row are given from @@ -23,7 +24,7 @@ typedef struct greymap_s greymap_t; /* macros for accessing pixel at index (x,y). Note that the origin is in the *lower* left corner. U* macros omit the bounds check. */ -#define gm_index(gm, x, y) (&(gm)->map[(x)+(y)*(ssize_t)(gm)->w]) +#define gm_index(gm, x, y) (&(gm)->map[(x)+(y)*(ptrdiff_t)(gm)->w]) #define gm_safe(gm, x, y) ((int)(x)>=0 && (int)(x)<(gm)->w && (int)(y)>=0 && (int)(y)<(gm)->h) #define gm_bound(x, m) ((x)<0 ? 0 : (x)>=(m) ? (m)-1 : (x)) #define GM_UGET(gm, x, y) (*gm_index(gm, x, y)) diff --git a/Build/source/libs/potrace/potrace-1.12/src/libpotrace-export.sym b/Build/source/libs/potrace/potrace-src/src/libpotrace-export.sym index 74d55c87482..74d55c87482 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/libpotrace-export.sym +++ b/Build/source/libs/potrace/potrace-src/src/libpotrace-export.sym diff --git a/Build/source/libs/potrace/potrace-1.12/src/lists.h b/Build/source/libs/potrace/potrace-src/src/lists.h index 394262c23ee..394262c23ee 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/lists.h +++ b/Build/source/libs/potrace/potrace-src/src/lists.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/lzw.c b/Build/source/libs/potrace/potrace-src/src/lzw.c index 89b5e0d4ce1..5281bba274b 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/lzw.c +++ b/Build/source/libs/potrace/potrace-src/src/lzw.c @@ -5,6 +5,10 @@ /* code for adaptive LZW compression, as used in PostScript. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdlib.h> #include <stdio.h> #include <errno.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/lzw.h b/Build/source/libs/potrace/potrace-src/src/lzw.h index 8ac3ed6a109..8ac3ed6a109 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/lzw.h +++ b/Build/source/libs/potrace/potrace-src/src/lzw.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/main.c b/Build/source/libs/potrace/potrace-src/src/main.c index bad84579d5e..a28a25ed40d 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/main.c +++ b/Build/source/libs/potrace/potrace-src/src/main.c @@ -2,11 +2,17 @@ This file is part of Potrace. It is free software and it is covered by the GNU General Public License. See the file COPYING for details. */ +#define _XOPEN_SOURCE 500 + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif #include <stdio.h> #include <stdlib.h> #include <errno.h> #include <string.h> +#include <strings.h> #include <getopt.h> #include <math.h> @@ -27,10 +33,6 @@ #include "progress_bar.h" #include "trans.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #ifndef M_PI #define M_PI 3.14159265358979323846 #endif diff --git a/Build/source/libs/potrace/potrace-1.12/src/main.h b/Build/source/libs/potrace/potrace-src/src/main.h index 3d4ae431ee2..f052c4f2b77 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/main.h +++ b/Build/source/libs/potrace/potrace-src/src/main.h @@ -7,7 +7,7 @@ #define MAIN_H #ifdef HAVE_CONFIG_H -#include "config.h" +#include <config.h> #endif #include "potracelib.h" diff --git a/Build/source/libs/potrace/potrace-1.12/src/mkbitmap.c b/Build/source/libs/potrace/potrace-src/src/mkbitmap.c index 276bafd2bc2..c8689326145 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/mkbitmap.c +++ b/Build/source/libs/potrace/potrace-src/src/mkbitmap.c @@ -7,6 +7,12 @@ filter (evening out background gradients), lowpass filter (smoothing foreground details), interpolated scaling, inversion. */ +#define _XOPEN_SOURCE 500 + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <errno.h> #include <string.h> @@ -18,10 +24,6 @@ #include "bitmap_io.h" #include "platform.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - #define SAFE_CALLOC(var, n, typ) \ if ((var = (typ *)calloc(n, sizeof(typ))) == NULL) goto calloc_error diff --git a/Build/source/libs/potrace/potrace-1.12/src/platform.h b/Build/source/libs/potrace/potrace-src/src/platform.h index 974ba1f861b..4fa1155ac4e 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/platform.h +++ b/Build/source/libs/potrace/potrace-src/src/platform.h @@ -8,7 +8,7 @@ #define PLATFORM_H #ifdef HAVE_CONFIG_H -#include "config.h" +#include <config.h> #endif /* in Windows, set all file i/o to binary */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/potracelib.c b/Build/source/libs/potrace/potrace-src/src/potracelib.c index 16e91024ed8..23f9669bd75 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/potracelib.c +++ b/Build/source/libs/potrace/potrace-src/src/potracelib.c @@ -2,6 +2,10 @@ This file is part of Potrace. It is free software and it is covered by the GNU General Public License. See the file COPYING for details. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdlib.h> #include <string.h> @@ -11,10 +15,6 @@ #include "trace.h" #include "progress.h" -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - /* default parameters */ static const potrace_param_t param_default = { 2, /* turdsize */ diff --git a/Build/source/libs/potrace/potrace-1.12/src/potracelib.h b/Build/source/libs/potrace/potrace-src/src/potracelib.h index 0a6ddbf1f63..0a6ddbf1f63 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/potracelib.h +++ b/Build/source/libs/potrace/potrace-src/src/potracelib.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/potracelib_demo.c b/Build/source/libs/potrace/potrace-src/src/potracelib_demo.c index ea8e8935fcb..65a787d61ce 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/potracelib_demo.c +++ b/Build/source/libs/potrace/potrace-src/src/potracelib_demo.c @@ -4,6 +4,10 @@ /* A simple and self-contained demo of the potracelib API */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <string.h> #include <errno.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/progress.h b/Build/source/libs/potrace/potrace-src/src/progress.h index dd93d79207a..dd93d79207a 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/progress.h +++ b/Build/source/libs/potrace/potrace-src/src/progress.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/progress_bar.c b/Build/source/libs/potrace/potrace-src/src/progress_bar.c index b0f2027c69d..acf75658a4f 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/progress_bar.c +++ b/Build/source/libs/potrace/potrace-src/src/progress_bar.c @@ -5,6 +5,10 @@ /* functions to render a progress bar for main.c. We provide a standard and a simplified progress bar. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <math.h> #include <stdlib.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/progress_bar.h b/Build/source/libs/potrace/potrace-src/src/progress_bar.h index c28cb8444f5..c28cb8444f5 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/progress_bar.h +++ b/Build/source/libs/potrace/potrace-src/src/progress_bar.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/render.c b/Build/source/libs/potrace/potrace-src/src/render.c index 4f44ae6a64d..38ba1c70024 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/render.c +++ b/Build/source/libs/potrace/potrace-src/src/render.c @@ -2,6 +2,9 @@ This file is part of Potrace. It is free software and it is covered by the GNU General Public License. See the file COPYING for details. */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif #include <stdio.h> #include <stdlib.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/render.h b/Build/source/libs/potrace/potrace-src/src/render.h index 0caaedff629..0caaedff629 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/render.h +++ b/Build/source/libs/potrace/potrace-src/src/render.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/trace.c b/Build/source/libs/potrace/potrace-src/src/trace.c index 469262b6799..7f92458284d 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/trace.c +++ b/Build/source/libs/potrace/potrace-src/src/trace.c @@ -4,6 +4,10 @@ /* transform jaggy paths into smooth curves */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <stdio.h> #include <math.h> #include <stdlib.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/trace.h b/Build/source/libs/potrace/potrace-src/src/trace.h index c53cdd10f25..c53cdd10f25 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/trace.h +++ b/Build/source/libs/potrace/potrace-src/src/trace.h diff --git a/Build/source/libs/potrace/potrace-1.12/src/trans.c b/Build/source/libs/potrace/potrace-src/src/trans.c index 55e72cacc5d..a3a9d95995a 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/trans.c +++ b/Build/source/libs/potrace/potrace-src/src/trans.c @@ -4,6 +4,10 @@ /* calculations with coordinate transformations and bounding boxes */ +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + #include <math.h> #include <string.h> diff --git a/Build/source/libs/potrace/potrace-1.12/src/trans.h b/Build/source/libs/potrace/potrace-src/src/trans.h index 40f37cd2ce5..40f37cd2ce5 100644 --- a/Build/source/libs/potrace/potrace-1.12/src/trans.h +++ b/Build/source/libs/potrace/potrace-src/src/trans.h diff --git a/Build/source/libs/potrace/version.ac b/Build/source/libs/potrace/version.ac index b00dd01de54..22ca5a5d99a 100644 --- a/Build/source/libs/potrace/version.ac +++ b/Build/source/libs/potrace/version.ac @@ -8,4 +8,4 @@ dnl dnl -------------------------------------------------------- dnl dnl m4-include this file to define the current potrace version -m4_define([potrace_version], [1.12]) +m4_define([potrace_version], [1.13]) |