Glib subproject git checkout isn't cached any more on the
GStreamer CI image, so use tarball for now, and update to
more recent glib.
This means we can no longer use --default-library=both on
Windows, so add separate jobs for static/shared build.
Since the if/else was replaced by a switch() here in 2e0075e265,
the size field of pbounds is not being set in the EXTEND_NONE case,
which means we end up passing uninitialized values to CGPatternCreate.
LZW compression: If the last input byte caused the code width to
increase, the end-of-data code was still output with the old (not yet
increased) code width.
Before this commit, cairo_pdf_version_to_string() would return the
result of an out-of-bounds array access when called with a negative
value. This commit adds a check against this.
No unit test added since there are no tests for
cairo_pdf_version_to_string() that I could easily add such a test to.
Fixes: https://gitlab.freedesktop.org/cairo/cairo/-/issues/590
Signed-off-by: Uli Schlachter <psychon@znc.in>
The rest of cairo (and therefore most external packages that depend
on cairo) doesn't make any use of liblzo.
Signed-off-by: Simon McVittie <smcv@debian.org>
Using `meson test` is the Meson equivalent of `make check`, and is the
way developers of other Meson-built projects will generally expect to
run tests. In particular, it encapsulates which of the tests want to be
run from which directories, removing the need for the Gitlab-CI
integration to know this.
Signed-off-by: Simon McVittie <smcv@debian.org>
Checking that public header files #include "cairo.h" first (or none)
Checking that private header files #include "some cairo header" first (or none)
Checking that source files #include "cairoint.h" first (or none)
./win32/cairo-dwrite-font-public.c:#include "cairo-win32-private.h"
Checking that there is no #include <cairo.*.h>
./win32/cairo-dwrite-font-public.c: * #include <cairo-win32.h>
Checking that feature conditionals are used with #if only (not #ifdef)
This adds a missing cairoint.h include and makes
check-preprocessor-syntax.sh slightly better in not warning about
includes in C comments.
Signed-off-by: Uli Schlachter <psychon@znc.in>
The autofoo build is on its way out and I am too lazy to properly
integrate these scripts with the meson build. Thus, this commit just
adds them to one single CI build. At least those that can relatively
easily be made to work. The others are left as comments.
Signed-off-by: Uli Schlachter <psychon@znc.in>
This wasn't previously marked as private because it was initially
static inline, and only became extern later.
Fixes: 9ffbf63d "fix warning: inlining failed in call to '_csi_stack_push'"
Resolves: https://gitlab.freedesktop.org/cairo/cairo/-/issues/580
Signed-off-by: Simon McVittie <smcv@debian.org>
cairo-trutype-subset.c would blindly trust a font saying that its name
list has thousands of entries. This commit changes find_name() to also
get the size of the input memory region and to do some bounds checking
on its memory accesses.
Fixes: https://gitlab.freedesktop.org/cairo/cairo/-/issues/579
Signed-off-by: Uli Schlachter <psychon@znc.in>