diff options
author | Michael Stahl <mstahl@redhat.com> | 2016-06-02 12:54:36 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-06-07 07:28:10 +0000 |
commit | 683d7260e1a193a82e5341700c253561ee3fee42 (patch) | |
tree | 99301b87551030d1a609390beca43c1932a3d7ee /connectivity/source/inc | |
parent | 0480d6b366fb52d44b19545e3f9511750ad15abd (diff) |
vcl: fix "sgv" import filter on 64-bit MSVC
This filter reads entire structs at a time from the SvStream, including
structs that are derived from other structs. This happens to work fine
with GCC by chance, but MSVC AMD64 by default aligns structs to 8 bytes,
and that means if sizeof(super-stuct) = 20 then 4 bytes of padding are
inserted and that ruins the import.
This causes vcl_filters_test to go into an infinite loop reading
SaveAsPicture.sgv.
Fix this by reading each member of the structs separately, which also
means that the filter doesn't need to byte-swap every member on
big-endian platforms since SvStream methods already do that.
Change-Id: I237725dbcde5232006728179e645776fcb79cac3
(cherry picked from commit af8509fa194e6747c82a9df9a1c465be82a32637)
Reviewed-on: https://gerrit.libreoffice.org/25988
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'connectivity/source/inc')
0 files changed, 0 insertions, 0 deletions