projects
/
platform
/
upstream
/
gst-plugins-good.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
53b9f87
)
j2kpay: handle EOC correctly
author
Wim Taymans
<wim.taymans@collabora.co.uk>
Thu, 16 Dec 2010 17:55:43 +0000
(18:55 +0100)
committer
Wim Taymans
<wim.taymans@collabora.co.uk>
Thu, 16 Dec 2010 17:57:27 +0000
(18:57 +0100)
Don't include the next 2 bytes when we are at the end of the data and there are
no more bytes left.
gst/rtp/gstrtpj2kpay.c
patch
|
blob
|
history
diff --git
a/gst/rtp/gstrtpj2kpay.c
b/gst/rtp/gstrtpj2kpay.c
index
7d98185
..
e427227
100644
(file)
--- a/
gst/rtp/gstrtpj2kpay.c
+++ b/
gst/rtp/gstrtpj2kpay.c
@@
-241,8
+241,8
@@
find_pu_end (GstRtpJ2KPay * pay, const guint8 * data, guint size,
GST_LOG_OBJECT (pay, "reached next SOT at %u", offset);
state->bitstream = FALSE;
state->force_packet = TRUE;
- if (marker == J2K_MARKER_EOC)
- /* include EOC */
+ if (marker == J2K_MARKER_EOC
&& state->next_sot + 2 <= size
)
+ /* include EOC
but never go past the max size
*/
return state->next_sot + 2;
else
return state->next_sot;