[libwps] 01/03: New upstream version 0.4.7

Rene Engelhard rene at moszumanska.debian.org
Mon Jul 17 17:17:12 UTC 2017


This is an automated email from the git hooks/post-receive script.

rene pushed a commit to branch master
in repository libwps.

commit 8075c5633ed556194bc46470c949b68b8bfa57f1
Author: Rene Engelhard <rene at rene-engelhard.de>
Date:   Mon Jul 17 19:14:55 2017 +0200

    New upstream version 0.4.7
---
 ChangeLog                      |  85 +++++++++
 NEWS                           |   4 +
 aclocal.m4                     |  16 +-
 configure                      | 114 ++++++++----
 configure.ac                   |  19 +-
 src/Makefile.am                |   3 +
 src/Makefile.in                |   5 +-
 src/conv/helper/helper.cpp     |   2 +-
 src/fuzz/123fuzzer.cpp         |  37 ++++
 src/fuzz/Makefile.am           |  56 ++++++
 src/{ => fuzz}/Makefile.in     | 407 ++++++++++++++++++++++++-----------------
 src/fuzz/docfuzzer.cpp         |  37 ++++
 src/fuzz/wdbfuzzer.cpp         |  37 ++++
 src/fuzz/wkfuzzer.cpp          |  37 ++++
 src/fuzz/wksfuzzer.cpp         |  37 ++++
 src/fuzz/wpsfuzzer.cpp         |  39 ++++
 src/fuzz/wqfuzzer.cpp          |  37 ++++
 src/fuzz/wrifuzzer.cpp         |  37 ++++
 src/lib/Lotus.cpp              |   2 +-
 src/lib/QuattroSpreadsheet.cpp |  38 ++--
 src/lib/WKS4Spreadsheet.cpp    |   2 +-
 src/lib/WKSContentListener.cpp |   4 +-
 src/lib/WPS4.cpp               |   4 +-
 src/lib/WPS4Text.cpp           |   9 +-
 src/lib/WPS8Table.cpp          |   2 +-
 src/lib/WPS8Text.cpp           |   5 +-
 src/lib/WPS8Text.h             |   2 +-
 src/lib/WPS8TextStyle.cpp      |   4 +-
 src/lib/WPSCell.cpp            |  11 +-
 src/lib/WPSContentListener.cpp |   6 +-
 src/lib/WPSDebug.h             |   2 +-
 src/lib/WPSGraphicShape.cpp    |   1 +
 src/lib/WPSPageSpan.cpp        |   1 +
 src/lib/libwps_internal.cpp    |   1 +
 src/lib/libwps_internal.h      |  14 ++
 src/lib/libwps_tools_win.cpp   |   1 +
 36 files changed, 864 insertions(+), 254 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 1596d1c..5adec71 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,88 @@
+2017-07-16  osnola  <alonso at loria.fr>  [b992069290a4c107bb424ef421ee82ba2ae31357]
+
+tconfigure.ac: update micro version
+
+
+2017-07-16  osnola  <alonso at loria.fr>  [81e5e931109c73e1216aaf4ec9b3de25a650b4ef]
+
+tUpdate README files...
+
+
+2017-07-03  osnola  <alonso at loria.fr>  [e1b2c2f34268d14aa469c88ab89bd9f491168bd0]
+
+tg++7: try to remove some warnings...
+
+
+2017-05-20  osnola  <alonso at loria.fr>  [82183981147344f4f56b69b71a572688542dce65]
+
+tQuattroSpreadsheet.cpp: correct wq1's formula when there is single and double cell's references...
+
+
+2017-04-25  David Tardon  <dtardon at redhat.com>  [282239bc81585de00613823c3768327f8b3ce540]
+
+tofz#1269 fix int overflow
+
+
+2017-04-20  David Tardon  <dtardon at redhat.com>  [b7b092e058807ddfc3d8b25c4702012425e3b04e]
+
+tofz#1083 fix signed integer overflow
+
+
+2017-04-12  David Tardon  <dtardon at redhat.com>  [711b02ce6a1280c79bcba9c9c87672914e32d377]
+
+tofz#1019 fix int overflow
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [d896b8f18a31a184a0a333bf6532ec143727e845]
+
+tadd wq? fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [036742c56e66888815e04ec9fa9e722830fddde7]
+
+tadd wk? fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [8db28cb07e95890da0027949e651bbb2fe81f003]
+
+tadd 123 fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [f54e898ca3408660cf7780504ac11ad1c6a8bd0d]
+
+tadd doc fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [0d98752779dad668536f9d8ddf16952e9ad6ed22]
+
+tadd wri fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [801b3d24fa1820fdbe5ea835a41a4658f3c56348]
+
+tadd wdb fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [82420322242a8d3ef8275eeec39456222be77365]
+
+tadd wks fuzzer
+
+
+2017-04-06  David Tardon  <dtardon at redhat.com>  [cfb4b672014a2f5cc81dec25f6cac6445d2d3f4e]
+
+tadd .gitignore
+
+
+2017-03-31  David Tardon  <dtardon at redhat.com>  [e65c68425ec5befe3c5961046925ad43be6b94d4]
+
+tastyle
+
+
+2017-03-31  David Tardon  <dtardon at redhat.com>  [0c1b069fc1f813a6b3c01fb074e3fc826dc07ae9]
+
+tadd fuzzing driver for oss-fuzz
+
+
 2017-03-04  osnola  <alonso at loria.fr>  [1d29e6f12d6928b2a39df41db5022c0f4ecdf4bb]
 
 tupdate some README's files...
diff --git a/NEWS b/NEWS
index 2966df0..7323f21 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,7 @@
+0.4.6 -> 0.4.7
+- correct many problem detected with fuzzing,
+- QuattroPro: correct reading of wq1 formula with references.
+
 0.4.5 -> 0.4.6
 - Lotus 123: add support to read SmartSuite 98's files,
 - Lotus: allow to convert file with a password.
diff --git a/aclocal.m4 b/aclocal.m4
index 483e43b..93b7f07 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -20,9 +20,9 @@ You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
 
-dnl pkg.m4 - Macros to locate and utilise pkg-config.   -*- Autoconf -*-
-dnl serial 11 (pkg-config-0.29.1)
-dnl
+# pkg.m4 - Macros to locate and utilise pkg-config.   -*- Autoconf -*-
+# serial 12 (pkg-config-0.29.2)
+
 dnl Copyright © 2004 Scott James Remnant <scott at netsplit.com>.
 dnl Copyright © 2012-2015 Dan Nicholson <dbn.lists at gmail.com>
 dnl
@@ -63,7 +63,7 @@ dnl
 dnl See the "Since" comment for each macro you use to see what version
 dnl of the macros you require.
 m4_defun([PKG_PREREQ],
-[m4_define([PKG_MACROS_VERSION], [0.29.1])
+[m4_define([PKG_MACROS_VERSION], [0.29.2])
 m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1,
     [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])])
 ])dnl PKG_PREREQ
@@ -164,7 +164,7 @@ AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
 AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
 
 pkg_failed=no
-AC_MSG_CHECKING([for $1])
+AC_MSG_CHECKING([for $2])
 
 _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
 _PKG_CONFIG([$1][_LIBS], [libs], [$2])
@@ -174,11 +174,11 @@ and $1[]_LIBS to avoid the need to call pkg-config.
 See the pkg-config man page for more details.])
 
 if test $pkg_failed = yes; then
-   	AC_MSG_RESULT([no])
+        AC_MSG_RESULT([no])
         _PKG_SHORT_ERRORS_SUPPORTED
         if test $_pkg_short_errors_supported = yes; then
 	        $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
-        else 
+        else
 	        $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
         fi
 	# Put the nasty error message in config.log where it belongs
@@ -195,7 +195,7 @@ installed software in a non-standard prefix.
 _PKG_TEXT])[]dnl
         ])
 elif test $pkg_failed = untried; then
-     	AC_MSG_RESULT([no])
+        AC_MSG_RESULT([no])
 	m4_default([$4], [AC_MSG_FAILURE(
 [The pkg-config script could not be found or is too old.  Make sure it
 is in your PATH or set the PKG_CONFIG environment variable to the full
diff --git a/configure b/configure
index f4c9dbe..d2f0bef 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for libwps 0.4.6.
+# Generated by GNU Autoconf 2.69 for libwps 0.4.7.
 #
 #
 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
@@ -587,8 +587,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='libwps'
 PACKAGE_TARNAME='libwps'
-PACKAGE_VERSION='0.4.6'
-PACKAGE_STRING='libwps 0.4.6'
+PACKAGE_VERSION='0.4.7'
+PACKAGE_STRING='libwps 0.4.7'
 PACKAGE_BUGREPORT=''
 PACKAGE_URL=''
 
@@ -632,12 +632,14 @@ ac_subst_vars='am__EXEEXT_FALSE
 am__EXEEXT_TRUE
 LTLIBOBJS
 LIBOBJS
-BUILD_TOOLS_FALSE
-BUILD_TOOLS_TRUE
 REVENGE_STREAM_LIBS
 REVENGE_STREAM_CFLAGS
 REVENGE_GENERATORS_LIBS
 REVENGE_GENERATORS_CFLAGS
+BUILD_FUZZERS_FALSE
+BUILD_FUZZERS_TRUE
+BUILD_TOOLS_FALSE
+BUILD_TOOLS_TRUE
 REVENGE_LIBS
 REVENGE_CFLAGS
 WITH_LIBWPS_DOCS_FALSE
@@ -815,6 +817,7 @@ enable_static_tools
 with_sharedptr
 with_docs
 enable_tools
+enable_fuzzers
 '
       ac_precious_vars='build_alias
 host_alias
@@ -1379,7 +1382,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 libwps 0.4.6 to adapt to many kinds of systems.
+\`configure' configures libwps 0.4.7 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1449,7 +1452,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of libwps 0.4.6:";;
+     short | recursive ) echo "Configuration of libwps 0.4.7:";;
    esac
   cat <<\_ACEOF
 
@@ -1477,6 +1480,7 @@ Optional Features:
   --enable-full-debug     Turn on debugging and debug files' creation
   --enable-static-tools   Link tools (binaries) statically
   --disable-tools         Build conversion tools
+  --enable-fuzzers        Build fuzzer(s)
 
 Optional Packages:
   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
@@ -1592,7 +1596,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-libwps configure 0.4.6
+libwps configure 0.4.7
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -1991,7 +1995,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 libwps $as_me 0.4.6, which was
+It was created by libwps $as_me 0.4.7, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -2857,7 +2861,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='libwps'
- VERSION='0.4.6'
+ VERSION='0.4.7'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -17156,9 +17160,9 @@ WPS_MAJOR_VERSION=0
 
 WPS_MINOR_VERSION=4
 
-WPS_MICRO_VERSION=6
+WPS_MICRO_VERSION=7
 
-WPS_VERSION=0.4.6
+WPS_VERSION=0.4.7
 
 WPS_OBJDIR=$objdir
 
@@ -17167,7 +17171,7 @@ LT_CURRENT=`expr 100 '*' 0 + 4`
 # For 1.0.0 comment the first line and uncomment the second
 LT_AGE=0
 
-LT_REVISION=6
+LT_REVISION=7
 
 
 
@@ -17837,8 +17841,8 @@ fi
 # ====================
 
 pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for REVENGE" >&5
-$as_echo_n "checking for REVENGE... " >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for  librevenge-0.0 " >&5
+$as_echo_n "checking for  librevenge-0.0 ... " >&6; }
 
 if test -n "$REVENGE_CFLAGS"; then
     pkg_cv_REVENGE_CFLAGS="$REVENGE_CFLAGS"
@@ -17878,7 +17882,7 @@ fi
 
 
 if test $pkg_failed = yes; then
-   	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 
 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
@@ -17905,7 +17909,7 @@ Alternatively, you may set the environment variables REVENGE_CFLAGS
 and REVENGE_LIBS to avoid the need to call pkg-config.
 See the pkg-config man page for more details." "$LINENO" 5
 elif test $pkg_failed = untried; then
-     	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
@@ -17940,12 +17944,45 @@ else
 
 fi
 
-if test "x$enable_tools" = "xyes"; then :
+ if test "x$enable_tools" = "xyes"; then
+  BUILD_TOOLS_TRUE=
+  BUILD_TOOLS_FALSE='#'
+else
+  BUILD_TOOLS_TRUE='#'
+  BUILD_TOOLS_FALSE=
+fi
+
+
+# =======
+# Fuzzers
+# =======
+# Check whether --enable-fuzzers was given.
+if test "${enable_fuzzers+set}" = set; then :
+  enableval=$enable_fuzzers; enable_fuzzers="$enableval"
+else
+  enable_fuzzers=no
+
+fi
+
+ if test "x$enable_fuzzers" = "xyes"; then
+  BUILD_FUZZERS_TRUE=
+  BUILD_FUZZERS_FALSE='#'
+else
+  BUILD_FUZZERS_TRUE='#'
+  BUILD_FUZZERS_FALSE=
+fi
+
+
+if test "x$enable_tools" = "xyes" -o "x$enable_fuzzers" = "xyes"; then :
 
 
 pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for REVENGE_GENERATORS" >&5
-$as_echo_n "checking for REVENGE_GENERATORS... " >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for
+		librevenge-generators-0.0
+	" >&5
+$as_echo_n "checking for
+		librevenge-generators-0.0
+	... " >&6; }
 
 if test -n "$REVENGE_GENERATORS_CFLAGS"; then
     pkg_cv_REVENGE_GENERATORS_CFLAGS="$REVENGE_GENERATORS_CFLAGS"
@@ -17997,7 +18034,7 @@ fi
 
 
 if test $pkg_failed = yes; then
-   	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 
 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
@@ -18030,7 +18067,7 @@ Alternatively, you may set the environment variables REVENGE_GENERATORS_CFLAGS
 and REVENGE_GENERATORS_LIBS to avoid the need to call pkg-config.
 See the pkg-config man page for more details." "$LINENO" 5
 elif test $pkg_failed = untried; then
-     	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
@@ -18053,8 +18090,12 @@ $as_echo "yes" >&6; }
 fi
 
 pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for REVENGE_STREAM" >&5
-$as_echo_n "checking for REVENGE_STREAM... " >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for
+		librevenge-stream-0.0
+	" >&5
+$as_echo_n "checking for
+		librevenge-stream-0.0
+	... " >&6; }
 
 if test -n "$REVENGE_STREAM_CFLAGS"; then
     pkg_cv_REVENGE_STREAM_CFLAGS="$REVENGE_STREAM_CFLAGS"
@@ -18106,7 +18147,7 @@ fi
 
 
 if test $pkg_failed = yes; then
-   	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 
 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
@@ -18139,7 +18180,7 @@ Alternatively, you may set the environment variables REVENGE_STREAM_CFLAGS
 and REVENGE_STREAM_LIBS to avoid the need to call pkg-config.
 See the pkg-config man page for more details." "$LINENO" 5
 elif test $pkg_failed = untried; then
-     	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+        { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
 $as_echo "no" >&6; }
 	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
@@ -18166,19 +18207,11 @@ fi
 
 
 
- if test "x$enable_tools" = "xyes"; then
-  BUILD_TOOLS_TRUE=
-  BUILD_TOOLS_FALSE='#'
-else
-  BUILD_TOOLS_TRUE='#'
-  BUILD_TOOLS_FALSE=
-fi
-
 
 # =====================
 # Prepare all .in files
 # =====================
-ac_config_files="$ac_config_files Makefile inc/Makefile inc/libwps/Makefile src/Makefile src/conv/Makefile src/conv/helper/Makefile src/conv/html/Makefile src/conv/html/wps2html.rc src/conv/raw/Makefile src/conv/raw/wps2raw.rc src/conv/text/Makefile src/conv/text/wps2text.rc src/conv/wks2csv/Makefile src/conv/wks2csv/wks2csv.rc src/conv/wks2raw/Makefile src/conv/wks2raw/wks2raw.rc src/conv/wks2text/Makefile src/conv/wks2text/wks2text.rc src/lib/Makefile src/lib/libwps.rc docs/Makefile do [...]
+ac_config_files="$ac_config_files Makefile inc/Makefile inc/libwps/Makefile src/Makefile src/conv/Makefile src/conv/helper/Makefile src/conv/html/Makefile src/conv/html/wps2html.rc src/conv/raw/Makefile src/conv/raw/wps2raw.rc src/conv/text/Makefile src/conv/text/wps2text.rc src/conv/wks2csv/Makefile src/conv/wks2csv/wks2csv.rc src/conv/wks2raw/Makefile src/conv/wks2raw/wks2raw.rc src/conv/wks2text/Makefile src/conv/wks2text/wks2text.rc src/fuzz/Makefile src/lib/Makefile src/lib/libwps.r [...]
 
 cat >confcache <<\_ACEOF
 # This file is a shell script that caches the results of configure
@@ -18345,6 +18378,10 @@ if test -z "${BUILD_TOOLS_TRUE}" && test -z "${BUILD_TOOLS_FALSE}"; then
   as_fn_error $? "conditional \"BUILD_TOOLS\" was never defined.
 Usually this means the macro was only invoked conditionally." "$LINENO" 5
 fi
+if test -z "${BUILD_FUZZERS_TRUE}" && test -z "${BUILD_FUZZERS_FALSE}"; then
+  as_fn_error $? "conditional \"BUILD_FUZZERS\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
 
 : "${CONFIG_STATUS=./config.status}"
 ac_write_fail=0
@@ -18742,7 +18779,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 libwps $as_me 0.4.6, which was
+This file was extended by libwps $as_me 0.4.7, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -18808,7 +18845,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="\\
-libwps config.status 0.4.6
+libwps config.status 0.4.7
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
@@ -19341,6 +19378,7 @@ do
     "src/conv/wks2raw/wks2raw.rc") CONFIG_FILES="$CONFIG_FILES src/conv/wks2raw/wks2raw.rc" ;;
     "src/conv/wks2text/Makefile") CONFIG_FILES="$CONFIG_FILES src/conv/wks2text/Makefile" ;;
     "src/conv/wks2text/wks2text.rc") CONFIG_FILES="$CONFIG_FILES src/conv/wks2text/wks2text.rc" ;;
+    "src/fuzz/Makefile") CONFIG_FILES="$CONFIG_FILES src/fuzz/Makefile" ;;
     "src/lib/Makefile") CONFIG_FILES="$CONFIG_FILES src/lib/Makefile" ;;
     "src/lib/libwps.rc") CONFIG_FILES="$CONFIG_FILES src/lib/libwps.rc" ;;
     "docs/Makefile") CONFIG_FILES="$CONFIG_FILES docs/Makefile" ;;
@@ -20798,6 +20836,7 @@ Build configuration:
 	debug:           ${enable_debug}
 	full-debug:      ${enable_full_debug}
 	docs:            ${build_docs}
+	fuzzers:         ${enable_fuzzers}
 	shared_ptr:      ${with_sharedptr}
 	static-tools:    ${enable_static_tools}
 	werror:          ${enable_werror}
@@ -20809,6 +20848,7 @@ Build configuration:
 	debug:           ${enable_debug}
 	full-debug:      ${enable_full_debug}
 	docs:            ${build_docs}
+	fuzzers:         ${enable_fuzzers}
 	shared_ptr:      ${with_sharedptr}
 	static-tools:    ${enable_static_tools}
 	werror:          ${enable_werror}
diff --git a/configure.ac b/configure.ac
index b2a2a80..e49f815 100644
--- a/configure.ac
+++ b/configure.ac
@@ -7,7 +7,7 @@ AC_PREREQ([2.65])
 # ====================
 m4_define([libwps_version_major],[0])
 m4_define([libwps_version_minor],[4])
-m4_define([libwps_version_micro],[6])
+m4_define([libwps_version_micro],[7])
 m4_define([libwps_version],[libwps_version_major.libwps_version_minor.libwps_version_micro])
 
 # =============
@@ -345,7 +345,19 @@ AC_ARG_ENABLE([tools],
 	[enable_tools="$enableval"],
 	[enable_tools=yes]
 )
-AS_IF([test "x$enable_tools" = "xyes"], [
+AM_CONDITIONAL(BUILD_TOOLS, [test "x$enable_tools" = "xyes"])
+
+# =======
+# Fuzzers
+# =======
+AC_ARG_ENABLE([fuzzers],
+	[AS_HELP_STRING([--enable-fuzzers], [Build fuzzer(s)])],
+	[enable_fuzzers="$enableval"],
+	[enable_fuzzers=no]
+)
+AM_CONDITIONAL(BUILD_FUZZERS, [test "x$enable_fuzzers" = "xyes"])
+
+AS_IF([test "x$enable_tools" = "xyes" -o "x$enable_fuzzers" = "xyes"], [
 	PKG_CHECK_MODULES([REVENGE_GENERATORS],[
 		librevenge-generators-0.0
 	])
@@ -357,7 +369,6 @@ AC_SUBST([REVENGE_GENERATORS_CFLAGS])
 AC_SUBST([REVENGE_GENERATORS_LIBS])
 AC_SUBST([REVENGE_STREAM_CFLAGS])
 AC_SUBST([REVENGE_STREAM_LIBS])
-AM_CONDITIONAL(BUILD_TOOLS, [test "x$enable_tools" = "xyes"])
 
 # =====================
 # Prepare all .in files
@@ -381,6 +392,7 @@ src/conv/wks2raw/Makefile
 src/conv/wks2raw/wks2raw.rc
 src/conv/wks2text/Makefile
 src/conv/wks2text/wks2text.rc
+src/fuzz/Makefile
 src/lib/Makefile
 src/lib/libwps.rc
 docs/Makefile
@@ -401,6 +413,7 @@ Build configuration:
 	debug:           ${enable_debug}
 	full-debug:      ${enable_full_debug}
 	docs:            ${build_docs}
+	fuzzers:         ${enable_fuzzers}
 	shared_ptr:      ${with_sharedptr}
 	static-tools:    ${enable_static_tools}
 	werror:          ${enable_werror}
diff --git a/src/Makefile.am b/src/Makefile.am
index db92e39..c83c78c 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -4,3 +4,6 @@ if BUILD_TOOLS
 SUBDIRS += conv
 endif
 
+if BUILD_FUZZERS
+SUBDIRS += fuzz
+endif
diff --git a/src/Makefile.in b/src/Makefile.in
index 83520ad..f8a63b3 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -88,6 +88,7 @@ POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
 @BUILD_TOOLS_TRUE at am__append_1 = conv
+ at BUILD_FUZZERS_TRUE@am__append_2 = fuzz
 subdir = src
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
@@ -155,7 +156,7 @@ am__define_uniq_tagged_files = \
   done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
-DIST_SUBDIRS = lib conv
+DIST_SUBDIRS = lib conv fuzz
 am__DIST_COMMON = $(srcdir)/Makefile.in
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 am__relativize = \
@@ -332,7 +333,7 @@ target_alias = @target_alias@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
-SUBDIRS = lib $(am__append_1)
+SUBDIRS = lib $(am__append_1) $(am__append_2)
 all: all-recursive
 
 .SUFFIXES:
diff --git a/src/conv/helper/helper.cpp b/src/conv/helper/helper.cpp
index 0d79486..cfbdc7d 100644
--- a/src/conv/helper/helper.cpp
+++ b/src/conv/helper/helper.cpp
@@ -104,7 +104,7 @@ public:
 	/*! \brief seeks to a offset position, from actual, beginning or ending position
 	 * \return 0 if ok
 	 */
-	int seek(long , librevenge::RVNG_SEEK_TYPE)
+	int seek(long, librevenge::RVNG_SEEK_TYPE)
 	{
 		return 1;
 	}
diff --git a/src/fuzz/123fuzzer.cpp b/src/fuzz/123fuzzer.cpp
new file mode 100644
index 0000000..6425e5f
--- /dev/null
+++ b/src/fuzz/123fuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawSpreadsheetGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/Makefile.am b/src/fuzz/Makefile.am
new file mode 100644
index 0000000..ee608a1
--- /dev/null
+++ b/src/fuzz/Makefile.am
@@ -0,0 +1,56 @@
+noinst_PROGRAMS = \
+	wpsfuzzer wksfuzzer wdbfuzzer wrifuzzer docfuzzer 123fuzzer \
+	wkfuzzer wqfuzzer
+
+AM_CXXFLAGS = -I$(top_srcdir)/inc \
+	$(REVENGE_GENERATORS_CFLAGS) \
+	$(REVENGE_CFLAGS) \
+	$(REVENGE_STREAM_CFLAGS) \
+	$(DEBUG_CXXFLAGS)
+
+commonfuzzer_ldadd = \
+	$(top_builddir)/src/lib/libwps- at WPS_MAJOR_VERSION@. at WPS_MINOR_VERSION@.la \
+	$(REVENGE_GENERATORS_LIBS) \
+	$(REVENGE_LIBS) \
+	$(REVENGE_STREAM_LIBS) \
+	-lFuzzingEngine
+
+wpsfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wpsfuzzer_SOURCES = \
+	wpsfuzzer.cpp
+
+wksfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wksfuzzer_SOURCES = \
+	wksfuzzer.cpp
+
+wdbfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wdbfuzzer_SOURCES = \
+	wdbfuzzer.cpp
+
+wrifuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wrifuzzer_SOURCES = \
+	wrifuzzer.cpp
+
+docfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+docfuzzer_SOURCES = \
+	docfuzzer.cpp
+
+123fuzzer_LDADD = $(commonfuzzer_ldadd)
+
+123fuzzer_SOURCES = \
+	123fuzzer.cpp
+
+wkfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wkfuzzer_SOURCES = \
+	wkfuzzer.cpp
+
+wqfuzzer_LDADD = $(commonfuzzer_ldadd)
+
+wqfuzzer_SOURCES = \
+	wqfuzzer.cpp
diff --git a/src/Makefile.in b/src/fuzz/Makefile.in
similarity index 58%
copy from src/Makefile.in
copy to src/fuzz/Makefile.in
index 83520ad..da1573b 100644
--- a/src/Makefile.in
+++ b/src/fuzz/Makefile.in
@@ -13,6 +13,7 @@
 # PARTICULAR PURPOSE.
 
 @SET_MAKE@
+
 VPATH = @srcdir@
 am__is_gnu_make = { \
   if test -z '$(MAKELEVEL)'; then \
@@ -87,8 +88,10 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
- at BUILD_TOOLS_TRUE@am__append_1 = conv
-subdir = src
+noinst_PROGRAMS = wpsfuzzer$(EXEEXT) wksfuzzer$(EXEEXT) \
+	wdbfuzzer$(EXEEXT) wrifuzzer$(EXEEXT) docfuzzer$(EXEEXT) \
+	123fuzzer$(EXEEXT) wkfuzzer$(EXEEXT) wqfuzzer$(EXEEXT)
+subdir = src/fuzz
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
 	$(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
@@ -101,6 +104,39 @@ mkinstalldirs = $(install_sh) -d
 CONFIG_HEADER = $(top_builddir)/config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+PROGRAMS = $(noinst_PROGRAMS)
+am_123fuzzer_OBJECTS = 123fuzzer.$(OBJEXT)
+123fuzzer_OBJECTS = $(am_123fuzzer_OBJECTS)
+am__DEPENDENCIES_1 =
+am__DEPENDENCIES_2 = $(top_builddir)/src/lib/libwps- at WPS_MAJOR_VERSION@. at WPS_MINOR_VERSION@.la \
+	$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \
+	$(am__DEPENDENCIES_1)
+123fuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+am_docfuzzer_OBJECTS = docfuzzer.$(OBJEXT)
+docfuzzer_OBJECTS = $(am_docfuzzer_OBJECTS)
+docfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wdbfuzzer_OBJECTS = wdbfuzzer.$(OBJEXT)
+wdbfuzzer_OBJECTS = $(am_wdbfuzzer_OBJECTS)
+wdbfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wkfuzzer_OBJECTS = wkfuzzer.$(OBJEXT)
+wkfuzzer_OBJECTS = $(am_wkfuzzer_OBJECTS)
+wkfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wksfuzzer_OBJECTS = wksfuzzer.$(OBJEXT)
+wksfuzzer_OBJECTS = $(am_wksfuzzer_OBJECTS)
+wksfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wpsfuzzer_OBJECTS = wpsfuzzer.$(OBJEXT)
+wpsfuzzer_OBJECTS = $(am_wpsfuzzer_OBJECTS)
+wpsfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wqfuzzer_OBJECTS = wqfuzzer.$(OBJEXT)
+wqfuzzer_OBJECTS = $(am_wqfuzzer_OBJECTS)
+wqfuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
+am_wrifuzzer_OBJECTS = wrifuzzer.$(OBJEXT)
+wrifuzzer_OBJECTS = $(am_wrifuzzer_OBJECTS)
+wrifuzzer_DEPENDENCIES = $(am__DEPENDENCIES_2)
 AM_V_P = $(am__v_P_ at AM_V@)
 am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
 am__v_P_0 = false
@@ -113,29 +149,39 @@ AM_V_at = $(am__v_at_ at AM_V@)
 am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
 am__v_at_0 = @
 am__v_at_1 = 
-SOURCES =
-DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
-	ctags-recursive dvi-recursive html-recursive info-recursive \
-	install-data-recursive install-dvi-recursive \
-	install-exec-recursive install-html-recursive \
-	install-info-recursive install-pdf-recursive \
-	install-ps-recursive install-recursive installcheck-recursive \
-	installdirs-recursive pdf-recursive ps-recursive \
-	tags-recursive uninstall-recursive
+DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)
+depcomp = $(SHELL) $(top_srcdir)/depcomp
+am__depfiles_maybe = depfiles
+am__mv = mv -f
+CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
+LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CXXFLAGS) $(CXXFLAGS)
+AM_V_CXX = $(am__v_CXX_ at AM_V@)
+am__v_CXX_ = $(am__v_CXX_ at AM_DEFAULT_V@)
+am__v_CXX_0 = @echo "  CXX     " $@;
+am__v_CXX_1 = 
+CXXLD = $(CXX)
+CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \
+	$(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CXXLD = $(am__v_CXXLD_ at AM_V@)
+am__v_CXXLD_ = $(am__v_CXXLD_ at AM_DEFAULT_V@)
+am__v_CXXLD_0 = @echo "  CXXLD   " $@;
+am__v_CXXLD_1 = 
+SOURCES = $(123fuzzer_SOURCES) $(docfuzzer_SOURCES) \
+	$(wdbfuzzer_SOURCES) $(wkfuzzer_SOURCES) $(wksfuzzer_SOURCES) \
+	$(wpsfuzzer_SOURCES) $(wqfuzzer_SOURCES) $(wrifuzzer_SOURCES)
+DIST_SOURCES = $(123fuzzer_SOURCES) $(docfuzzer_SOURCES) \
+	$(wdbfuzzer_SOURCES) $(wkfuzzer_SOURCES) $(wksfuzzer_SOURCES) \
+	$(wpsfuzzer_SOURCES) $(wqfuzzer_SOURCES) $(wrifuzzer_SOURCES)
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
-RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
-  distclean-recursive maintainer-clean-recursive
-am__recursive_targets = \
-  $(RECURSIVE_TARGETS) \
-  $(RECURSIVE_CLEAN_TARGETS) \
-  $(am__extra_recursive_targets)
-AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
-	distdir
 am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 # Read a list of newline-separated strings from the standard input,
 # and print each of them once, without duplicates.  Input order is
@@ -155,34 +201,8 @@ am__define_uniq_tagged_files = \
   done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
-DIST_SUBDIRS = lib conv
-am__DIST_COMMON = $(srcdir)/Makefile.in
+am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
-am__relativize = \
-  dir0=`pwd`; \
-  sed_first='s,^\([^/]*\)/.*$$,\1,'; \
-  sed_rest='s,^[^/]*/*,,'; \
-  sed_last='s,^.*/\([^/]*\)$$,\1,'; \
-  sed_butlast='s,/*[^/]*$$,,'; \
-  while test -n "$$dir1"; do \
-    first=`echo "$$dir1" | sed -e "$$sed_first"`; \
-    if test "$$first" != "."; then \
-      if test "$$first" = ".."; then \
-        dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
-        dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
-      else \
-        first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
-        if test "$$first2" = "$$first"; then \
-          dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
-        else \
-          dir2="../$$dir2"; \
-        fi; \
-        dir0="$$dir0"/"$$first"; \
-      fi; \
-    fi; \
-    dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
-  done; \
-  reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
 AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
@@ -332,10 +352,55 @@ target_alias = @target_alias@
 top_build_prefix = @top_build_prefix@
 top_builddir = @top_builddir@
 top_srcdir = @top_srcdir@
-SUBDIRS = lib $(am__append_1)
-all: all-recursive
+AM_CXXFLAGS = -I$(top_srcdir)/inc \
+	$(REVENGE_GENERATORS_CFLAGS) \
+	$(REVENGE_CFLAGS) \
+	$(REVENGE_STREAM_CFLAGS) \
+	$(DEBUG_CXXFLAGS)
+
+commonfuzzer_ldadd = \
+	$(top_builddir)/src/lib/libwps- at WPS_MAJOR_VERSION@. at WPS_MINOR_VERSION@.la \
+	$(REVENGE_GENERATORS_LIBS) \
+	$(REVENGE_LIBS) \
+	$(REVENGE_STREAM_LIBS) \
+	-lFuzzingEngine
+
+wpsfuzzer_LDADD = $(commonfuzzer_ldadd)
+wpsfuzzer_SOURCES = \
+	wpsfuzzer.cpp
+
+wksfuzzer_LDADD = $(commonfuzzer_ldadd)
+wksfuzzer_SOURCES = \
+	wksfuzzer.cpp
+
+wdbfuzzer_LDADD = $(commonfuzzer_ldadd)
+wdbfuzzer_SOURCES = \
+	wdbfuzzer.cpp
+
+wrifuzzer_LDADD = $(commonfuzzer_ldadd)
+wrifuzzer_SOURCES = \
+	wrifuzzer.cpp
+
+docfuzzer_LDADD = $(commonfuzzer_ldadd)
+docfuzzer_SOURCES = \
+	docfuzzer.cpp
+
+123fuzzer_LDADD = $(commonfuzzer_ldadd)
+123fuzzer_SOURCES = \
+	123fuzzer.cpp
+
+wkfuzzer_LDADD = $(commonfuzzer_ldadd)
+wkfuzzer_SOURCES = \
+	wkfuzzer.cpp
+
+wqfuzzer_LDADD = $(commonfuzzer_ldadd)
+wqfuzzer_SOURCES = \
+	wqfuzzer.cpp
+
+all: all-am
 
 .SUFFIXES:
+.SUFFIXES: .cpp .lo .o .obj
 $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -345,9 +410,9 @@ $(srcdir)/Makefile.in:  $(srcdir)/Makefile.am  $(am__configure_deps)
 	      exit 1;; \
 	  esac; \
 	done; \
-	echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \
+	echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/fuzz/Makefile'; \
 	$(am__cd) $(top_srcdir) && \
-	  $(AUTOMAKE) --foreign src/Makefile
+	  $(AUTOMAKE) --foreign src/fuzz/Makefile
 Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
 	@case '$?' in \
 	  *config.status*) \
@@ -366,67 +431,97 @@ $(ACLOCAL_M4):  $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
 
+clean-noinstPROGRAMS:
+	@list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
+	echo " rm -f" $$list; \
+	rm -f $$list || exit $$?; \
+	test -n "$(EXEEXT)" || exit 0; \
+	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
+	echo " rm -f" $$list; \
+	rm -f $$list
+
+123fuzzer$(EXEEXT): $(123fuzzer_OBJECTS) $(123fuzzer_DEPENDENCIES) $(EXTRA_123fuzzer_DEPENDENCIES) 
+	@rm -f 123fuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(123fuzzer_OBJECTS) $(123fuzzer_LDADD) $(LIBS)
+
+docfuzzer$(EXEEXT): $(docfuzzer_OBJECTS) $(docfuzzer_DEPENDENCIES) $(EXTRA_docfuzzer_DEPENDENCIES) 
+	@rm -f docfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(docfuzzer_OBJECTS) $(docfuzzer_LDADD) $(LIBS)
+
+wdbfuzzer$(EXEEXT): $(wdbfuzzer_OBJECTS) $(wdbfuzzer_DEPENDENCIES) $(EXTRA_wdbfuzzer_DEPENDENCIES) 
+	@rm -f wdbfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wdbfuzzer_OBJECTS) $(wdbfuzzer_LDADD) $(LIBS)
+
+wkfuzzer$(EXEEXT): $(wkfuzzer_OBJECTS) $(wkfuzzer_DEPENDENCIES) $(EXTRA_wkfuzzer_DEPENDENCIES) 
+	@rm -f wkfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wkfuzzer_OBJECTS) $(wkfuzzer_LDADD) $(LIBS)
+
+wksfuzzer$(EXEEXT): $(wksfuzzer_OBJECTS) $(wksfuzzer_DEPENDENCIES) $(EXTRA_wksfuzzer_DEPENDENCIES) 
+	@rm -f wksfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wksfuzzer_OBJECTS) $(wksfuzzer_LDADD) $(LIBS)
+
+wpsfuzzer$(EXEEXT): $(wpsfuzzer_OBJECTS) $(wpsfuzzer_DEPENDENCIES) $(EXTRA_wpsfuzzer_DEPENDENCIES) 
+	@rm -f wpsfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wpsfuzzer_OBJECTS) $(wpsfuzzer_LDADD) $(LIBS)
+
+wqfuzzer$(EXEEXT): $(wqfuzzer_OBJECTS) $(wqfuzzer_DEPENDENCIES) $(EXTRA_wqfuzzer_DEPENDENCIES) 
+	@rm -f wqfuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wqfuzzer_OBJECTS) $(wqfuzzer_LDADD) $(LIBS)
+
+wrifuzzer$(EXEEXT): $(wrifuzzer_OBJECTS) $(wrifuzzer_DEPENDENCIES) $(EXTRA_wrifuzzer_DEPENDENCIES) 
+	@rm -f wrifuzzer$(EXEEXT)
+	$(AM_V_CXXLD)$(CXXLINK) $(wrifuzzer_OBJECTS) $(wrifuzzer_LDADD) $(LIBS)
+
+mostlyclean-compile:
+	-rm -f *.$(OBJEXT)
+
+distclean-compile:
+	-rm -f *.tab.c
+
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/123fuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/docfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wdbfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wkfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wksfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wpsfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wqfuzzer.Po at am__quote@
+ at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/wrifuzzer.Po at am__quote@
+
+.cpp.o:
+ at am__fastdepCXX_TRUE@	$(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCXX_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCXX_FALSE@	$(AM_V_CXX at am__nodep@)$(CXXCOMPILE) -c -o $@ $<
+
+.cpp.obj:
+ at am__fastdepCXX_TRUE@	$(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCXX_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCXX_FALSE@	$(AM_V_CXX at am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+
+.cpp.lo:
+ at am__fastdepCXX_TRUE@	$(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCXX_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	$(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at AMDEP_TRUE@@am__fastdepCXX_FALSE@	DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+ at am__fastdepCXX_FALSE@	$(AM_V_CXX at am__nodep@)$(LTCXXCOMPILE) -c -o $@ $<
+
 mostlyclean-libtool:
 	-rm -f *.lo
 
 clean-libtool:
 	-rm -rf .libs _libs
 
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run 'make' without going through this Makefile.
-# To change the values of 'make' variables: instead of editing Makefiles,
-# (1) if the variable is set in 'config.status', edit 'config.status'
-#     (which will cause the Makefiles to be regenerated when you run 'make');
-# (2) otherwise, pass the desired values on the 'make' command line.
-$(am__recursive_targets):
-	@fail=; \
-	if $(am__make_keepgoing); then \
-	  failcom='fail=yes'; \
-	else \
-	  failcom='exit 1'; \
-	fi; \
-	dot_seen=no; \
-	target=`echo $@ | sed s/-recursive//`; \
-	case "$@" in \
-	  distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
-	  *) list='$(SUBDIRS)' ;; \
-	esac; \
-	for subdir in $$list; do \
-	  echo "Making $$target in $$subdir"; \
-	  if test "$$subdir" = "."; then \
-	    dot_seen=yes; \
-	    local_target="$$target-am"; \
-	  else \
-	    local_target="$$target"; \
-	  fi; \
-	  ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
-	  || eval $$failcom; \
-	done; \
-	if test "$$dot_seen" = "no"; then \
-	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
-	fi; test -z "$$fail"
-
 ID: $(am__tagged_files)
 	$(am__define_uniq_tagged_files); mkid -fID $$unique
-tags: tags-recursive
+tags: tags-am
 TAGS: tags
 
 tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
-	  include_option=--etags-include; \
-	  empty_fix=.; \
-	else \
-	  include_option=--include; \
-	  empty_fix=; \
-	fi; \
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  if test "$$subdir" = .; then :; else \
-	    test ! -f $$subdir/TAGS || \
-	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
-	  fi; \
-	done; \
 	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
@@ -439,7 +534,7 @@ tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	      $$unique; \
 	  fi; \
 	fi
-ctags: ctags-recursive
+ctags: ctags-am
 
 CTAGS: ctags
 ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
@@ -452,7 +547,7 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
-cscopelist: cscopelist-recursive
+cscopelist: cscopelist-am
 
 cscopelist-am: $(am__tagged_files)
 	list='$(am__tagged_files)'; \
@@ -501,45 +596,19 @@ distdir: $(DISTFILES)
 	    || exit 1; \
 	  fi; \
 	done
-	@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
-	  if test "$$subdir" = .; then :; else \
-	    $(am__make_dryrun) \
-	      || test -d "$(distdir)/$$subdir" \
-	      || $(MKDIR_P) "$(distdir)/$$subdir" \
-	      || exit 1; \
-	    dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
-	    $(am__relativize); \
-	    new_distdir=$$reldir; \
-	    dir1=$$subdir; dir2="$(top_distdir)"; \
-	    $(am__relativize); \
-	    new_top_distdir=$$reldir; \
-	    echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
-	    echo "     am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
-	    ($(am__cd) $$subdir && \
-	      $(MAKE) $(AM_MAKEFLAGS) \
-	        top_distdir="$$new_top_distdir" \
-	        distdir="$$new_distdir" \
-		am__remove_distdir=: \
-		am__skip_length_check=: \
-		am__skip_mode_fix=: \
-	        distdir) \
-	      || exit 1; \
-	  fi; \
-	done
 check-am: all-am
-check: check-recursive
-all-am: Makefile
-installdirs: installdirs-recursive
-installdirs-am:
-install: install-recursive
-install-exec: install-exec-recursive
-install-data: install-data-recursive
-uninstall: uninstall-recursive
+check: check-am
+all-am: Makefile $(PROGRAMS)
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
 
 install-am: all-am
 	@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
 
-installcheck: installcheck-recursive
+installcheck: installcheck-am
 install-strip:
 	if test -z '$(STRIP)'; then \
 	  $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
@@ -561,86 +630,92 @@ distclean-generic:
 maintainer-clean-generic:
 	@echo "This command is intended for maintainers to use"
 	@echo "it deletes files that may require special tools to rebuild."
-clean: clean-recursive
+clean: clean-am
 
-clean-am: clean-generic clean-libtool mostlyclean-am
+clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
+	mostlyclean-am
 
-distclean: distclean-recursive
+distclean: distclean-am
+	-rm -rf ./$(DEPDIR)
 	-rm -f Makefile
-distclean-am: clean-am distclean-generic distclean-tags
+distclean-am: clean-am distclean-compile distclean-generic \
+	distclean-tags
 
-dvi: dvi-recursive
+dvi: dvi-am
 
 dvi-am:
 
-html: html-recursive
+html: html-am
 
 html-am:
 
-info: info-recursive
+info: info-am
 
 info-am:
 
 install-data-am:
 
-install-dvi: install-dvi-recursive
+install-dvi: install-dvi-am
 
 install-dvi-am:
 
 install-exec-am:
 
-install-html: install-html-recursive
+install-html: install-html-am
 
 install-html-am:
 
-install-info: install-info-recursive
+install-info: install-info-am
 
 install-info-am:
 
 install-man:
 
-install-pdf: install-pdf-recursive
+install-pdf: install-pdf-am
 
 install-pdf-am:
 
-install-ps: install-ps-recursive
+install-ps: install-ps-am
 
 install-ps-am:
 
 installcheck-am:
 
-maintainer-clean: maintainer-clean-recursive
+maintainer-clean: maintainer-clean-am
+	-rm -rf ./$(DEPDIR)
 	-rm -f Makefile
 maintainer-clean-am: distclean-am maintainer-clean-generic
 
-mostlyclean: mostlyclean-recursive
+mostlyclean: mostlyclean-am
 
-mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+	mostlyclean-libtool
 
-pdf: pdf-recursive
+pdf: pdf-am
 
 pdf-am:
 
-ps: ps-recursive
+ps: ps-am
 
 ps-am:
 
 uninstall-am:
 
-.MAKE: $(am__recursive_targets) install-am install-strip
-
-.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
-	check-am clean clean-generic clean-libtool cscopelist-am ctags \
-	ctags-am distclean distclean-generic distclean-libtool \
-	distclean-tags distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-info install-info-am install-man \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	installdirs-am maintainer-clean maintainer-clean-generic \
-	mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
-	ps ps-am tags tags-am uninstall uninstall-am
+.MAKE: install-am install-strip
+
+.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
+	clean-libtool clean-noinstPROGRAMS cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am install-info \
+	install-info-am install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs maintainer-clean \
+	maintainer-clean-generic mostlyclean mostlyclean-compile \
+	mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+	tags tags-am uninstall uninstall-am
 
 .PRECIOUS: Makefile
 
diff --git a/src/fuzz/docfuzzer.cpp b/src/fuzz/docfuzzer.cpp
new file mode 100644
index 0000000..aad2b67
--- /dev/null
+++ b/src/fuzz/docfuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawTextGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wdbfuzzer.cpp b/src/fuzz/wdbfuzzer.cpp
new file mode 100644
index 0000000..6425e5f
--- /dev/null
+++ b/src/fuzz/wdbfuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawSpreadsheetGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wkfuzzer.cpp b/src/fuzz/wkfuzzer.cpp
new file mode 100644
index 0000000..6425e5f
--- /dev/null
+++ b/src/fuzz/wkfuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawSpreadsheetGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wksfuzzer.cpp b/src/fuzz/wksfuzzer.cpp
new file mode 100644
index 0000000..6425e5f
--- /dev/null
+++ b/src/fuzz/wksfuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawSpreadsheetGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wpsfuzzer.cpp b/src/fuzz/wpsfuzzer.cpp
new file mode 100644
index 0000000..adf8f25
--- /dev/null
+++ b/src/fuzz/wpsfuzzer.cpp
@@ -0,0 +1,39 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2006, 2007 Andrew Ziem
+ * Copyright (C) 2004 Marc Maurer (uwog at uwog.net)
+ * Copyright (C) 2004-2006 Fridrich Strba (fridrich.strba at bluewin.ch)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawTextGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wqfuzzer.cpp b/src/fuzz/wqfuzzer.cpp
new file mode 100644
index 0000000..6425e5f
--- /dev/null
+++ b/src/fuzz/wqfuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawSpreadsheetGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/fuzz/wrifuzzer.cpp b/src/fuzz/wrifuzzer.cpp
new file mode 100644
index 0000000..aad2b67
--- /dev/null
+++ b/src/fuzz/wrifuzzer.cpp
@@ -0,0 +1,37 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
+/* libwps
+ * Version: MPL 2.0 / LGPLv2.1+
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * Major Contributor(s):
+ * Copyright (C) 2017 David Tardon (dtardon at redhat.com)
+ *
+ * For minor contributions see the git repository.
+ *
+ * Alternatively, the contents of this file may be used under the terms
+ * of the GNU Lesser General Public License Version 2.1 or later
+ * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
+ * applicable instead of those above.
+ */
+
+#include <cstdint>
+#include <cstdlib>
+
+#include <librevenge-generators/librevenge-generators.h>
+
+#include <librevenge-stream/librevenge-stream.h>
+
+#include <libwps/libwps.h>
+
+extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
+{
+	librevenge::RVNGStringStream input(data, size);
+	librevenge::RVNGRawTextGenerator generator(true);
+	libwps::WPSDocument::parse(&input, &generator);
+	return 0;
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
diff --git a/src/lib/Lotus.cpp b/src/lib/Lotus.cpp
index 407606b..0725ff6 100644
--- a/src/lib/Lotus.cpp
+++ b/src/lib/Lotus.cpp
@@ -198,7 +198,7 @@ struct State
 				s << "[F" << i << "]";
 			if (m_actualLevels[i][0]==m_actualLevels[i][1])
 				s << "_";
-			else if (m_actualLevels[i][0]+1==m_actualLevels[i][1])
+			else if (m_actualLevels[i][0]==m_actualLevels[i][1]-1)
 				s << m_actualLevels[i][0];
 			else
 				s << m_actualLevels[i][0] << "x" << m_actualLevels[i][1]-1;
diff --git a/src/lib/QuattroSpreadsheet.cpp b/src/lib/QuattroSpreadsheet.cpp
index aaf7f55..8072ac9 100644
--- a/src/lib/QuattroSpreadsheet.cpp
+++ b/src/lib/QuattroSpreadsheet.cpp
@@ -440,7 +440,7 @@ public:
 struct State
 {
 	//! constructor
-	State() :  m_eof(-1), m_version(-1), m_hasLICSCharacters(-1), m_styleManager(), m_spreadsheetList(), m_spreadsheetStack()
+	State() :  m_eof(-1), m_version(-1), m_maxDimension(0,0,0), m_hasLICSCharacters(-1), m_styleManager(), m_spreadsheetList(), m_spreadsheetStack()
 	{
 		pushNewSheet(shared_ptr<Spreadsheet>(new Spreadsheet(Spreadsheet::T_Spreadsheet, 0)));
 	}
@@ -506,6 +506,8 @@ struct State
 	long m_eof;
 	//! the file version
 	int m_version;
+	//! the maximum col, row, sheet
+	WPSVec3i m_maxDimension;
 	//! int to code if the file has LICS characters:-1 means unknown, 0 means no, 1 means yes
 	int m_hasLICSCharacters;
 	//! the style manager
@@ -579,13 +581,14 @@ bool QuattroSpreadsheet::readSheetSize()
 		return false;
 	}
 	long sz = libwps::readU16(m_input);
-	if (sz < 8)
+	int const vers=version();
+	if (sz < (vers>=2 ? 12 : 8))
 	{
 		WPS_DEBUG_MSG(("QuattroSpreadsheet::readSheetSize: block is too short\n"));
 		return false;
 	}
 	f << "Entries(SheetSize):";
-	for (int i = 0; i < 2; i++)   // always 2 zero ?
+	for (int i = 0; i < (vers>=2 ? 3 : 2); i++)   // always 2 zero ?
 	{
 		int val = libwps::read16(m_input);
 		if (!val) continue;
@@ -595,12 +598,15 @@ bool QuattroSpreadsheet::readSheetSize()
 	f << "nCols=" << nCol << ",";
 	int nRow =  libwps::read16(m_input);
 	f << "nRow=" << nRow << ",";
+	int nSheet =  vers<=1 ? 0 : libwps::read16(m_input);
+	if (nSheet>0)
+		f << "nSheet=" << nSheet << ",";
+	m_state->m_maxDimension=WPSVec3i(nCol,nRow,nSheet);
 	ascii().addPos(pos);
 	ascii().addNote(f.str().c_str());
 	// empty spreadsheet
 	if (nRow==-1 && nCol==0) return true;
 	if (nRow < 0 || nCol <= 0) return false;
-
 	m_state->getActualSheet().setColumnWidth(nCol-1);
 	return true;
 
@@ -1296,9 +1302,11 @@ bool QuattroSpreadsheet::readUserStyle()
 		break;
 	}
 	style.m_fileFormat=(int) libwps::readU8(m_input);
-	int dim[2];
-	for (int i=0; i<2; ++i) dim[i]=(int) libwps::read16(m_input);
-	if (dim[0]||dim[1]) f << "dim=" << Vec2i(dim[0],dim[1]) << ",";
+	for (int i=0; i<3; ++i)
+	{
+		val=(int) libwps::read8(m_input);
+		if (val) f << "f" << i+2 << "=" << val << ",";
+	}
 
 	style.m_extra=f.str();
 	m_state->m_styleManager.add(id, style);
@@ -1812,7 +1820,6 @@ bool QuattroSpreadsheet::readFormula(long endPos, Vec2i const &position, int she
 	if (endPos-pos-2 != sz) return false;
 
 	std::vector<WKSContentListener::FormulaInstruction> listCellsPos;
-	size_t actCellId=0;
 	int fieldPos[2]= {0,sz};
 	for (int i=0; i<2; ++i)
 	{
@@ -1825,6 +1832,7 @@ bool QuattroSpreadsheet::readFormula(long endPos, Vec2i const &position, int she
 		error="###fieldPos";
 		return false;
 	}
+	int NSingle=0;
 	if (fieldPos[0]!=sz)
 	{
 		m_input->seek(pos+2+fieldPos[0], librevenge::RVNG_SEEK_SET);
@@ -1832,6 +1840,7 @@ bool QuattroSpreadsheet::readFormula(long endPos, Vec2i const &position, int she
 		if (vers==1)
 		{
 			int N=(int)(sz-fieldPos[0])/4;
+			NSingle=(int)(fieldPos[1]-fieldPos[0])/4;
 			for (int i=0; i<N; ++i)
 			{
 				WKSContentListener::FormulaInstruction cell;
@@ -1887,6 +1896,7 @@ bool QuattroSpreadsheet::readFormula(long endPos, Vec2i const &position, int she
 	std::stringstream f;
 	std::vector<std::vector<WKSContentListener::FormulaInstruction> > stack;
 	bool ok = true;
+	size_t actCellId=0, actDualCellId=size_t(NSingle);
 	while (long(m_input->tell()) != endPos)
 	{
 		double val;
@@ -1935,19 +1945,19 @@ bool QuattroSpreadsheet::readFormula(long endPos, Vec2i const &position, int she
 				instr=listCellsPos[actCellId++];
 				break;
 			}
-			if (actCellId+1>=listCellsPos.size())
+			if (actDualCellId+1>=listCellsPos.size())
 			{
 				f.str("");
-				f << "###unknListCell" << actCellId;
+				f << "###unknListCell" << actDualCellId;
 				error=f.str();
 				ok = false;
 				break;
 			}
-			instr=listCellsPos[actCellId++];
+			instr=listCellsPos[actDualCellId++];
 			instr.m_type=WKSContentListener::FormulaInstruction::F_CellList;
-			instr.m_position[1]=listCellsPos[actCellId].m_position[0];
-			instr.m_positionRelative[1]=listCellsPos[actCellId].m_positionRelative[0];
-			++actCellId;
+			instr.m_position[1]=listCellsPos[actDualCellId].m_position[0];
+			instr.m_positionRelative[1]=listCellsPos[actDualCellId].m_positionRelative[0];
+			++actDualCellId;
 			break;
 		case 0x5:
 			instr.m_type=WKSContentListener::FormulaInstruction::F_Long;
diff --git a/src/lib/WKS4Spreadsheet.cpp b/src/lib/WKS4Spreadsheet.cpp
index 29dd98e..cf3232c 100644
--- a/src/lib/WKS4Spreadsheet.cpp
+++ b/src/lib/WKS4Spreadsheet.cpp
@@ -821,7 +821,7 @@ bool WKS4Spreadsheet::readMsWorksStyle()
 			break;
 		case 5: // center arround cell
 			f << ",center[between cell]";
-		// fail through expected
+			WPS_FALLTHROUGH;
 		case 2:
 			style.setHAlignement(WPSCell::HALIGN_CENTER);
 			break;
diff --git a/src/lib/WKSContentListener.cpp b/src/lib/WKSContentListener.cpp
index 08d8209..d24b8a2 100644
--- a/src/lib/WKSContentListener.cpp
+++ b/src/lib/WKSContentListener.cpp
@@ -775,7 +775,7 @@ void WKSContentListener::_handleFrameParameters
 	{
 	case WPSPosition::YFull:
 		propList.insert("svg:height", double(h), unit);
-	// fall-through intended
+		WPS_FALLTHROUGH;
 	case WPSPosition::YTop:
 		if (origin[1] < 0.0 || origin[1] > 0.0)
 		{
@@ -819,7 +819,7 @@ void WKSContentListener::_handleFrameParameters
 	{
 	case WPSPosition::XFull:
 		propList.insert("svg:width", double(w), unit);
-	// fallthrough intended
+		WPS_FALLTHROUGH;
 	case WPSPosition::XLeft:
 		if (origin[0] < 0.0 || origin[0] > 0.0)
 		{
diff --git a/src/lib/WPS4.cpp b/src/lib/WPS4.cpp
index f6eb3c5..2629086 100644
--- a/src/lib/WPS4.cpp
+++ b/src/lib/WPS4.cpp
@@ -585,7 +585,7 @@ bool WPS4Parser::findZones()
 		{
 		case 0xda1:
 			apCreator = 2;
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case 0:
 		case 1:
 			worksVersion = 1;
@@ -752,7 +752,7 @@ bool WPS4Parser::findZones()
 	}
 
 	int num = libwps::readU16(input);
-	int sz = libwps::readU16(input);
+	long sz = libwps::readU16(input);
 	begP = (long) libwps::readU32(input);
 	if (begP)
 	{
diff --git a/src/lib/WPS4Text.cpp b/src/lib/WPS4Text.cpp
index 77cc38e..fe464ce 100644
--- a/src/lib/WPS4Text.cpp
+++ b/src/lib/WPS4Text.cpp
@@ -910,6 +910,7 @@ bool WPS4Text::readText(WPSEntry const &zone)
 					}
 					m_input->seek(-1, librevenge::RVNG_SEEK_CUR);
 				}
+				WPS_FALLTHROUGH;
 			default:
 				if (version()<=2)
 				{
@@ -1294,7 +1295,7 @@ bool WPS4Text::findFDPStructuresByHand(int which)
 }
 
 // PLC Data: default parser
-bool WPS4Text::defDataParser(long , long , int , long endPos, std::string &mess)
+bool WPS4Text::defDataParser(long, long, int, long endPos, std::string &mess)
 {
 	mess = "";
 	libwps::DebugStream f;
@@ -1593,7 +1594,7 @@ bool WPS4Text::readDosLink(WPSEntry const &entry)
 			val = libwps::readU16(m_input); // always 4
 			if (val != 4) f << "g1=" << val << ",";
 		}
-		// fall-through intended
+		WPS_FALLTHROUGH;
 		case 0x40: // spreadsheet range
 		case 0x01: // char ?
 		{
@@ -1999,7 +2000,7 @@ bool WPS4Text::readParagraph(long endPos, int &id, std::string &mess)
 				break;
 			case 0x13: // seems another way to define the left margin
 				f << "#left,";
-			// fall-through intended
+				WPS_FALLTHROUGH;
 			case 0x12:
 				pp.m_margins[1] = arg/1440.;
 				break;
@@ -2565,7 +2566,7 @@ bool WPS4Text::readPLC
 				break;
 			default:
 				WPS_DEBUG_MSG(("WPS4Text:readPLC: unexpected PLC size\n"));
-			// fallthrough intended
+				WPS_FALLTHROUGH;
 			case 0:
 				plc.m_value = 0;
 			}
diff --git a/src/lib/WPS8Table.cpp b/src/lib/WPS8Table.cpp
index 3280158..da6bfa9 100644
--- a/src/lib/WPS8Table.cpp
+++ b/src/lib/WPS8Table.cpp
@@ -605,7 +605,7 @@ bool WPS8Table::readMCLD(RVNGInputStreamPtr input, WPSEntry const &entry)
 						break; // normal
 					case 0xFF: // also unset, diff with value = 1 ?
 						f2 << "#f" << dt.id() << "=" << std::hex << dt.m_value << std::dec << ",";
-					// fall-through intended
+						WPS_FALLTHROUGH;
 					case 1:
 						cell->setVerticalSet(false);
 						break;
diff --git a/src/lib/WPS8Text.cpp b/src/lib/WPS8Text.cpp
index 5849c79..e91a8fc 100644
--- a/src/lib/WPS8Text.cpp
+++ b/src/lib/WPS8Text.cpp
@@ -22,6 +22,7 @@
 #include <stdlib.h>
 #include <string.h>
 
+#include <limits>
 #include <map>
 
 #include "libwps_internal.h"
@@ -1338,7 +1339,7 @@ void WPS8Text::createNotesCorrespondance()
 // plc: default, strs
 ////////////////////////////////////////////////////////////
 bool WPS8Text::defDataParser
-(long , long , int , WPS8Struct::FileData const &data, std::string &mess)
+(long, long, int, WPS8Struct::FileData const &data, std::string &mess)
 {
 	mess = "";
 	libwps::DebugStream f;
@@ -1819,7 +1820,7 @@ bool WPS8Text::tokenEndDataParser(long endPage, std::vector<long> const &textPtr
 		}
 		f << "ptr=(";
 
-		if (pos+20+4*N > endPage)
+		if (N < 0 || N > std::numeric_limits<int>::max()/4 || 4*N > endPage-pos+20)
 		{
 			input->seek(pos, librevenge::RVNG_SEEK_SET);
 			return false;
diff --git a/src/lib/WPS8Text.h b/src/lib/WPS8Text.h
index d1543dd..ae5796c 100644
--- a/src/lib/WPS8Text.h
+++ b/src/lib/WPS8Text.h
@@ -166,7 +166,7 @@ protected:
 	             EndDataParser endParser = 0L);
 	//! default parser
 	bool defDataParser
-	(long , long , int , WPS8Struct::FileData const &data, std::string &mess);
+	(long, long, int, WPS8Struct::FileData const &data, std::string &mess);
 	//! the text zones parser: STRS
 	bool textZonesDataParser(long bot, long eot, int nId,
 	                         WPS8Struct::FileData const &data,
diff --git a/src/lib/WPS8TextStyle.cpp b/src/lib/WPS8TextStyle.cpp
index aa02e49..dbaeb71 100644
--- a/src/lib/WPS8TextStyle.cpp
+++ b/src/lib/WPS8TextStyle.cpp
@@ -671,6 +671,7 @@ bool WPS8TextStyle::readParagraph(long endPos, int &id, std::string &mess)
 			{
 			case 2: // not frequent: only found one time
 				f << "#type[bullet]=2,";
+				WPS_FALLTHROUGH;
 			case 1: // the normal case
 				para.m_listLevelIndex = 1;
 				para.m_listLevel.m_type = libwps::BULLET;
@@ -756,7 +757,7 @@ bool WPS8TextStyle::readParagraph(long endPos, int &id, std::string &mess)
 					break;
 				default:
 					f << "#bullet/type=" << type << ",";
-				// fall-through intended
+					WPS_FALLTHROUGH;
 				case 2:
 					para.m_listLevel.m_type = libwps::ARABIC;
 					break;
@@ -1001,6 +1002,7 @@ bool WPS8TextStyle::readParagraph(long endPos, int &id, std::string &mess)
 				f << "extra[tabs]=[" << data.m_recursData[ch] << "],";
 			}
 		}
+		WPS_FALLTHROUGH; // checkme
 
 		case 0x34: // interline line spacing 8*152400 -> normal, sinon *2
 		{
diff --git a/src/lib/WPSCell.cpp b/src/lib/WPSCell.cpp
index 7086140..d87ea0b 100644
--- a/src/lib/WPSCell.cpp
+++ b/src/lib/WPSCell.cpp
@@ -64,12 +64,14 @@ bool WPSCellFormat::convertDTFormat(std::string const &dtFormat, librevenge::RVN
 		{
 		case 'Y':
 			list.insert("number:style", "long");
+			WPS_FALLTHROUGH;
 		case 'y':
 			list.insert("librevenge:value-type", "year");
 			propVect.append(list);
 			break;
 		case 'B':
 			list.insert("number:style", "long");
+			WPS_FALLTHROUGH;
 		case 'b':
 		case 'h':
 			list.insert("librevenge:value-type", "month");
@@ -82,13 +84,14 @@ bool WPSCellFormat::convertDTFormat(std::string const &dtFormat, librevenge::RVN
 			break;
 		case 'e':
 			list.insert("number:style", "long");
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case 'd':
 			list.insert("librevenge:value-type", "day");
 			propVect.append(list);
 			break;
 		case 'A':
 			list.insert("number:style", "long");
+			WPS_FALLTHROUGH;
 		case 'a':
 			list.insert("librevenge:value-type", "day-of-week");
 			propVect.append(list);
@@ -96,7 +99,7 @@ bool WPSCellFormat::convertDTFormat(std::string const &dtFormat, librevenge::RVN
 
 		case 'H':
 			list.insert("number:style", "long");
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case 'I':
 			list.insert("librevenge:value-type", "hours");
 			propVect.append(list);
@@ -286,11 +289,11 @@ bool WPSCellFormat::getNumberingProperties(librevenge::RVNGPropertyList &propLis
 		{
 		case 5: // thousand
 			propList.insert("number:grouping", true);
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case 0: // default
 			if (m_subFormat==0)
 				propList.remove("number:decimal-places");
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case 1: // decimal
 			propList.insert("librevenge:value-type", "number");
 			break;
diff --git a/src/lib/WPSContentListener.cpp b/src/lib/WPSContentListener.cpp
index 9d5e390..5994e51 100644
--- a/src/lib/WPSContentListener.cpp
+++ b/src/lib/WPSContentListener.cpp
@@ -1183,7 +1183,7 @@ bool WPSContentListener::openGroup(WPSPosition const &pos)
 	default:
 		WPS_DEBUG_MSG(("WPSContentListener::openGroup: UNKNOWN position, insert as char position\n"));
 #endif
-	// fallthrough intended
+		WPS_FALLTHROUGH;
 	case WPSPosition::CharBaseLine:
 	case WPSPosition::Char:
 		if (m_ps->m_isSpanOpened)
@@ -1372,7 +1372,7 @@ void WPSContentListener::_handleFrameParameters
 		{
 		case WPSPosition::YFull:
 			propList.insert("svg:height", double(h), unit);
-		// fall-through intended
+			WPS_FALLTHROUGH;
 		case WPSPosition::YTop:
 			if (origin[1] < 0.0 || origin[1] > 0.0)
 			{
@@ -1416,7 +1416,7 @@ void WPSContentListener::_handleFrameParameters
 		{
 		case WPSPosition::XFull:
 			propList.insert("svg:width", double(w), unit);
-		// fallthrough intended
+			WPS_FALLTHROUGH;
 		case WPSPosition::XLeft:
 			if (origin[0] < 0.0 || origin[0] > 0.0)
 			{
diff --git a/src/lib/WPSDebug.h b/src/lib/WPSDebug.h
index 51fee5e..830d93f 100644
--- a/src/lib/WPSDebug.h
+++ b/src/lib/WPSDebug.h
@@ -212,7 +212,7 @@ public:
 
 	static void reset() { }
 
-	static void skipZone(long , long) {}
+	static void skipZone(long, long) {}
 };
 }
 #  endif
diff --git a/src/lib/WPSGraphicShape.cpp b/src/lib/WPSGraphicShape.cpp
index 6a73f8b..6c60213 100644
--- a/src/lib/WPSGraphicShape.cpp
+++ b/src/lib/WPSGraphicShape.cpp
@@ -631,6 +631,7 @@ std::vector<WPSGraphicShape::PathData> WPSGraphicShape::getPath(bool forTransfor
 			break;
 		}
 	}
+	WPS_FALLTHROUGH;
 	case Arc:
 	case Pie:
 	{
diff --git a/src/lib/WPSPageSpan.cpp b/src/lib/WPSPageSpan.cpp
index f4d2fca..0444680 100644
--- a/src/lib/WPSPageSpan.cpp
+++ b/src/lib/WPSPageSpan.cpp
@@ -114,6 +114,7 @@ void WPSPageSpan::setHeaderFooter(const HeaderFooterType type, const HeaderFoote
 	{
 	case NEVER:
 		_removeHeaderFooter(type, ALL);
+		WPS_FALLTHROUGH;
 	case FIRST:
 	case ALL:
 		_removeHeaderFooter(type, ODD);
diff --git a/src/lib/libwps_internal.cpp b/src/lib/libwps_internal.cpp
index 73d1999..0be82b4 100644
--- a/src/lib/libwps_internal.cpp
+++ b/src/lib/libwps_internal.cpp
@@ -488,6 +488,7 @@ librevenge::RVNGString WPSField::getString() const
 		struct tm timeinfo;
 		if (localtime_r(&now, &timeinfo))
 		{
+#pragma GCC diagnostic ignored "-Wformat-nonliteral"
 			char buf[256];
 			strftime(buf, 256, format.c_str(), &timeinfo);
 			res=librevenge::RVNGString(buf);
diff --git a/src/lib/libwps_internal.h b/src/lib/libwps_internal.h
index 690dedb..8e91806 100644
--- a/src/lib/libwps_internal.h
+++ b/src/lib/libwps_internal.h
@@ -83,6 +83,20 @@ struct WPS_shared_ptr_noop_deleter
 	void operator()(T *) {}
 };
 
+/** fall through attributes */
+#define WPS_FALLTHROUGH
+#if defined(__clang__)
+#  if defined(__has_cpp_attribute) && __has_cpp_attribute(clang::fallthrough)
+#    undef WPS_FALLTHROUGH
+#    define WPS_FALLTHROUGH [[clang::fallthrough]]
+#  endif
+#elif defined(__GNUC__)
+#  if __GNUC__>=7
+#    undef WPS_FALLTHROUGH
+#    define WPS_FALLTHROUGH __attribute__ ((fallthrough))
+#  endif
+#endif
+
 // basic classes and autoptr
 /** shared pointer to librevenge::RVNGInputStream */
 typedef shared_ptr<librevenge::RVNGInputStream> RVNGInputStreamPtr;
diff --git a/src/lib/libwps_tools_win.cpp b/src/lib/libwps_tools_win.cpp
index 80f53c7..2868267 100644
--- a/src/lib/libwps_tools_win.cpp
+++ b/src/lib/libwps_tools_win.cpp
@@ -186,6 +186,7 @@ Font::Type Font::getTypeForOEM(int oem)
 
 	default:
 		WPS_DEBUG_MSG(("libwps_tools_win::Font::getTypeForOEM: find unknown oem %d\n", oem));
+		WPS_FALLTHROUGH;
 	case 0:
 		return UNKNOWN;
 	}

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-openoffice/libwps.git



More information about the Pkg-openoffice-commits mailing list