mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
jpegparse: fix endianness
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5838>
This commit is contained in:
parent
470b90a14a
commit
ae55ebfdf2
1 changed files with 8 additions and 0 deletions
|
@ -464,11 +464,19 @@ gst_jpeg_parse_app0 (GstJpegParse * parse, GstJpegSegment * seg)
|
|||
return FALSE;
|
||||
|
||||
/* x density */
|
||||
#if G_BYTE_ORDER == G_LITTLE_ENDIAN
|
||||
if (!gst_byte_reader_get_uint16_le (&reader, &xd))
|
||||
return FALSE;
|
||||
/* y density */
|
||||
if (!gst_byte_reader_get_uint16_le (&reader, &yd))
|
||||
return FALSE;
|
||||
#else
|
||||
if (!gst_byte_reader_get_uint16_be (&reader, &xd))
|
||||
return FALSE;
|
||||
/* y density */
|
||||
if (!gst_byte_reader_get_uint16_be (&reader, &yd))
|
||||
return FALSE;
|
||||
#endif
|
||||
|
||||
/* x thumbnail */
|
||||
if (!gst_byte_reader_get_uint8 (&reader, &xt))
|
||||
|
|
Loading…
Reference in a new issue