Showing with 6,357 additions and 7,720 deletions.
  1. +1 −1 .appveyor.yml
  2. +52 −0 ChangeLog
  3. +9 −1 NEWS
  4. +1 −1 README
  5. +15 −14 configure.ac
  6. +2,691 −2,695 examples/alldxf_0.inc
  7. +3,447 −4,932 examples/alldxf_1.inc
  8. +0 −2 examples/alldxf_2.inc
  9. +17 −11 m4/ax_add_fortify_source.m4
  10. +6 −5 m4/ax_restrict.m4
  11. +3 −3 programs/dwg2SVG.1
  12. +3 −3 programs/dwg2dxf.1
  13. +3 −3 programs/dwg2ps.1
  14. +3 −3 programs/dwgbmp.1
  15. +3 −3 programs/dwggrep.1
  16. +3 −3 programs/dwglayers.1
  17. +3 −3 programs/dwgread.1
  18. +3 −3 programs/dwgrewrite.1
  19. +3 −3 programs/dwgwrite.1
  20. +3 −3 programs/dxf2dwg.1
  21. +19 −0 src/bits.c
  22. +3 −0 src/config.h.in
  23. +2 −4 src/dec_macros.h
  24. +38 −15 src/decode.c
  25. +7 −3 src/dwg.c
  26. +6 −5 src/dwg.spec
  27. +11 −0 src/in_dxf.c
  28. +1 −0 src/in_dxfb.c
  29. +1 −1 test/unit-testing/tests_common.h
2 changes: 1 addition & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version: 0.9.2.{build}
version: 0.9.3.{build}
max_jobs: 4
environment:
matrix:
Expand Down
52 changes: 52 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,6 +1,58 @@
Full history from the git log
-----------------------------

2019-12-25 Reini Urban <rurban@cpan.org>

Release 0.9.3

2019-12-25 Reini Urban <rurban@cpan.org>

enable ax_restrict
re-format docs: autoconf-archive is pretty strict
gcc-9.2 on fedora has it fixed.

enable it. we do have several small inlined functions with loops on arrays,
so it might affects us. See GH #141

2019-12-25 Reini Urban <rurban@cpan.org>

fix -Wcpp warning with AX_ADD_FORTIFY_SOURCE

protect from invalid preR13 table numbers
various int overflows. Fixes GH #176, case 8.

add more preR13 error handling.
Fixes the remaining GH #176 case 9

more illegal preR13 protections
and optional byte overflow counter to abort >200
errors. Helpful in fuzzing, but not really useful for
libs, the program must install a SIGABRT handler then.
Fixes part of the remaining GH #176 case 9 (id:000024)

2019-12-24 Reini Urban <rurban@cpan.org>

fix REPEAT overflow check for <r2004
earlier DWGs can also be broken to include wrong REPEAT counts.
Fixes Case 3 of GH #176

fix ref double-free on error
Let the ref loop in dwg_free() free those refs.
Fixes case 5 of GH #176.

fix illegal SPLINE scenarios
from fuzzed DWGs, See GH #176, case 1

2019-12-20 Reini Urban <rurban@cpan.org>

fix dwg_find_table_extname -Wnull-dereference

use format(ms_printf) only on _WIN32
silences a few warnings

fix theoretical strncpy truncations
gcc-9 warns too much to my taste.

2019-11-07 Reini Urban <rurban@cpan.org>

geom: fix transform_OCS
Expand Down
10 changes: 9 additions & 1 deletion NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@ GNU LibreDWG NEWS -- history of user-visible changes. -*-indented-text-*-
Copyright (C) 2019 Free Software Foundation, Inc.
See the end for copying conditions.

LibreDWG version 0.9.3 - released 2019/12/25 - beta:

Minor bugfixes:
* Added several overflow checks from fuzzing (#176)
* Enabled AX_RESTRICT, undefining restrict in broken compilers (#141)
* Fixed AX_ADD_FORTIFY_SOURCE warnings with gcc-9 -Wcpp
* Disallow illegal SPLINE scenarios (#176)

LibreDWG version 0.9.2 - released 2019/11/08 - beta:

new API:
Expand All @@ -16,7 +24,7 @@ Minor bugfixes:
for each layer. (#166)

Other newsworthy changes:
* Add geom utils to some programs: dwg2SVG and dwgps to transcode
* Add geom utils to some programs: dwg2SVG and dwg2ps to transcode
points via its OCS (i.e. extrusion vector)
* Add basic POLYLINE_2D and LWPOLYLINE support to dwg2SVG. no arcs (bulges),
no other curve_types (spline, bezier), no widths.
Expand Down
2 changes: 1 addition & 1 deletion README
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ See INSTALL for generic instructions. Basically, you do:
$ sh ./autogen.sh (if you checked out the source code from git)
$ ./configure [--enable-trace] [--disable--write] [--disable-shared]
$ make
$ make check # optional but strongly encouraged while LibreDWG is alpha
$ make check
$ sudo make install

This builds and installs various files in the "installation dirs":
Expand Down
29 changes: 15 additions & 14 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ ac_cv_func_realloc_0_nonnull=yes
AC_CHECK_HEADERS([stdlib.h string.h stddef.h unistd.h malloc.h wchar.h ctype.h \
libgen.h getopt.h alloca.h valgrind/valgrind.h])
AX_INCLUDE_STRCASECMP
# AX_RESTRICT

# Don't bother testing for libps headers if libps is not available.
if test yes = "$libredwg_have_libps" ; then
Expand Down Expand Up @@ -175,7 +174,6 @@ AX_GCC_FUNC_ATTRIBUTE(gnu_format)
AX_GCC_FUNC_ATTRIBUTE(ms_format)
AX_GCC_FUNC_ATTRIBUTE(format)
AX_GCC_FUNC_ATTRIBUTE(malloc)
AX_ADD_FORTIFY_SOURCE

dnl until we can make a release, favor no -O2 optims.
dnl it's fast enough and better for debugging.
Expand Down Expand Up @@ -224,6 +222,21 @@ case $host in
esac
dnl x86_64-mingw-w64-gcc-9.2 is seriously broken, and not just mingw-w64

dnl --enable-debug sets DEBUG_CLASSES, will crash acad import
AC_MSG_CHECKING([--enable-debug])
AC_ARG_ENABLE([debug],AS_HELP_STRING([--enable-debug],[
Enable unstable DEBUG_CLASSES (default: no).]),
[if test x$ac_compiler_gnu = xyes; then
CFLAGS="`echo $CFLAGS|sed 's,-O2,,'` -fno-omit-frame-pointer"
fi
CFLAGS="$CFLAGS -DDEBUG_CLASSES"]
AC_MSG_RESULT([yes]),
AC_MSG_RESULT([no (default)]))
AM_CONDITIONAL([ENABLE_DEBUG], [test x$enable_debug = xyes])

AX_ADD_FORTIFY_SOURCE
AX_RESTRICT

dnl Feature: --disable-write
AC_MSG_CHECKING([--disable-write])
AC_ARG_ENABLE([write],AS_HELP_STRING([--disable-write],[
Expand Down Expand Up @@ -251,18 +264,6 @@ AC_CHECK_FUNCS([setenv],[],
[AC_MSG_RESULT([setenv not needed. no --enable-trace.])]
))

dnl --enable-debug sets DEBUG_CLASSES, will crash acad import
AC_MSG_CHECKING([--enable-debug])
AC_ARG_ENABLE([debug],AS_HELP_STRING([--enable-debug],[
Enable unstable DEBUG_CLASSES (default: no).]),
[if test x$ac_compiler_gnu = xyes; then
CFLAGS="`echo $CFLAGS|sed 's,-O2,,'` -fno-omit-frame-pointer"
fi
CFLAGS="$CFLAGS -DDEBUG_CLASSES"]
AC_MSG_RESULT([yes]),
AC_MSG_RESULT([no (default)]))
AM_CONDITIONAL([ENABLE_DEBUG], [test x$enable_debug = xyes])

dnl --disable-dxf only useful for faster debug/test cycles
AC_MSG_CHECKING([--disable-dxf])
AC_ARG_ENABLE([dxf],AS_HELP_STRING([--disable-dxf],[
Expand Down
Loading