| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| |
| | |
Fix some GIR annotations
See merge request GNOME/gdk-pixbuf!146
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
With this change, gdk-pixbuf can be consumed as a subproject without
making any changes to the build files of a project. All you need to do
is provide a wrap file with a `[provide]` section:
https://mesonbuild.com/Wrap-dependency-system-manual.html#provide-section
This is also necessary because otherwise projects need to hard-code
the subproject name, which might be `gdk-pixbuf` when using `wrap-git`
or `gdk-pixbuf-2.42.10` when using `wrap-file` (to build from
a release tarball). This can cause conflicts between different
subprojects that consume gdk-pixbuf differently.
Other projects like glib, cairo, pango, etc already do this.
|
|/
|
|
|
|
| |
Let's play some more whack-a-mole.
Fixes: #218
|
|
|
|
|
|
|
|
|
| |
As fix for security issue #205 when loading image data the memory size
was limited to 100 MB. That seemed like a good threshold. For larger
images, from around 18 megapixels (MP) and up though not for all such
images, this threshold was too low. Increasing the threshold too 300 MB
seems to work better and lets larger images load.
Fixes #216.
|
|\
| |
| |
| |
| | |
Disable relocation when built as a static libary on Windows
See merge request GNOME/gdk-pixbuf!136
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Specially crafted JPEG images may lead to a crash when their size is too
large; in the most benign of cases, the OS might terminate the process
after it tries to allocate all the memory in the world.
We can tell libjpeg to limit the size of the memory pool when loading,
to avoid this kind of result. For the time being, 100 MB seems like a
good threshold.
Original patch by: Sam Ezeh <sam.z.ezeh@gmail.com>
Fixes: #205
|
| |
| |
| |
| |
| |
| |
| |
| | |
This value is the number of bits for each symbol (i.e. colour index) decoded via LZW.
The maximum LZW code is specified as 12 bits, so the value here can only be 11 as two additional code words are required (clear and end of information) that immediately uses an additional bit.
This implementation has always been wrong, and the Firefox implementation has the same issue so it seems a common misinterpretation of the spec.
This has been changed here to avoid an assertion later in the LZW decoder.
Note that there is never any reason for a GIF to be encoded with more than 8 bits of colour information, as the colour tables only support up to 8 bits.
|
|/ |
|
|
|
|
|
|
| |
uninitialized memory
Fixes https://gitlab.gnome.org/GNOME/gdk-pixbuf/-/issues/199
|
|
|
|
| |
The return value of GdkPixbufModuleBeginLoadFunc is NULL only on error.
|
|
|
|
| |
Make sure that the array is annotated as zero-terminated.
|
|\
| |
| |
| |
| | |
Turn GdkPixbufModule functions into typed callbacks
See merge request GNOME/gdk-pixbuf!123
|
| |
| |
| |
| | |
This way we can properly document and annotate them.
|
|\ \
| | |
| | |
| | |
| | | |
tiff: Use non-deprecated C99 integer types
See merge request GNOME/gdk-pixbuf!124
|
| |/
| |
| |
| |
| | |
The old `uint16` and `uint32` types have been deprecated in favour of
the C99 integer types `uint16_t` and `uint32_t`.
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | | |
jpeg: Do not rely on UB around setjmp/longjmp
Closes #143
See merge request GNOME/gdk-pixbuf!116
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We are reading and writing a structure before and after a
sigsetjmp/longjmp pair without declaring it volatile. This is undefined
behaviour, and even if most compilers and toolchains won't have any
issue with that, it's better to avoid it if at all possible.
The simplest fix is to declare the variable in a separate function, and
then pass it by reference.
Fixes: #143
|
| |/
|/|
| |
| |
| |
| | |
Fixes: #190
Similar to fix in 086e8adf4cc352cd11572f96066b001b545f354e
|
| |
| |
| |
| | |
Reference the anchor in the class description.
|
|/
|
|
|
|
| |
The native loaders for Windows are not stored in a dictionary.
Fixes: #185
|
|
|
|
| |
Never use g_set_error() without a format string.
|
|
|
|
|
| |
The path of a file may contain non-Unicode glyphs, as file names have
their own encoding.
|
|
|
|
|
|
|
| |
This reverts commit f265a94336c17716b2dcb33198ec34ebf926f98e.
This change requires Meson ≥ 0.56, and Fedora 33 still has 0.55.3. We're
going to un-revert the change once we can depend on a newer version.
|
|
|
|
| |
Makes it slightly easier to visually parse and modify.
|
|
|
|
| |
Avoids a ton of string manipulations, and leaves escaping to Meson.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Use proper summaries; remove gtk-doc'isms; document properties.
|
|
|
|
| |
Different introspection file, different API reference.
|
|
|
|
|
| |
Drop the gtk-doc SECTION markers, and move documentation to classes or
separate documents.
|
|
|
|
|
|
|
|
|
|
|
| |
Use the idiomatic form:
#ifndef __FOO_H__
#define __FOO_H__
...
#endif /* __FOO_H__ */
|
|
|
|
| |
The syntax is "Deprecated: version: message".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix the following build failure:
../gdk-pixbuf/gdk-pixbuf-io.c: In function 'gdk_pixbuf_io_init':
../gdk-pixbuf/gdk-pixbuf-io.c:681:16: error: implicit declaration of function 'gdk_pixbuf_get_module_file'; did you mean '_gdk_pixbuf_get_module'? [-Werror=implicit-function-declaration]
681 | module_file = gdk_pixbuf_get_module_file ();
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
| _gdk_pixbuf_get_module
Fixes:
- http://autobuild.buildroot.org/results/6cd54c497f5d19342ec94ece713547b887e4c02d
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
|
|
|
|
| |
Meson's gnome module could want to find programs such as
gdk-pixbuf-pixdata when invoking glib-compile-resources.
|
|
|
|
|
|
|
|
|
|
|
|
| |
The code originally failed to load GIFs that had this set (4607c8e9) and then
changed to silently ignoring it (af71489c).
Reverting to the background on the first frame seems completely reasonable and
is the behaviour of Firefox/Chrome. The
[current GIF spec](https://www.w3.org/Graphics/GIF/spec-gif89a.txt) doesn't
indicate any issue doing this and it matches what Firefox/Chrome does.
Fixes https://gitlab.gnome.org/GNOME/gdk-pixbuf/-/issues/166
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As documented in the introductory comment, the interface of the various
functions in the GIF loader is that they read all the bytes they need,
or return -1 if not enough are available. Since commit
5212d69f "gif: Replace old buffer management code with GByteArray",
the incremental loader strictly depends on that assumption.
Unfortunately, gif_init() didn't conform to that interface. If there
were enough bytes available for the GIF signature (GIF87a or GIF89a)
but not enough bytes for the screen descriptor, it would return -1
having already consumed the first 6 bytes of the stream. A subsequent
retry with more data available would start from the beginning of the
screen descriptor, and immediately raise an error because the screen
descriptor is extremely unlikely to start with another copy of the
"GIF8" magic number.
The regression test tests/pixbuf-short-gif-write.c would have detected
this, but was accidentally disabled by commit 7f0b214a "tests:
Conditionally build and run tests".
This seems most easily fixed by reading the whole of the 13-byte
fixed-length header in one go. Adjust the offsets into the buffer
used to parse the screen descriptor accordingly.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
|
|
|
|
| |
Use g_once_init_enter/leave to ensure that enumeration types can be
registered across threads.
|
|
|
|
|
|
|
|
|
| |
The code value after a reset wasn't being validated, which means we would
accept invalid codes. This could cause an infinite loop in the decoder.
Fixes CVE-2020-29385
Fixes https://gitlab.gnome.org/GNOME/gdk-pixbuf/-/issues/164
|
|
|
|
|
|
|
|
| |
as the background.
This was a regression introduced in 5212d69f2362f9b68ccf9385277e5c4a744b2187.
Fixes https://gitlab.gnome.org/GNOME/gdk-pixbuf/-/issues/162
|
|
|
|
| |
We must handle the error path, where the out argument isn't set.
|
| |
|