summaryrefslogtreecommitdiffstats
path: root/spudec.c
diff options
context:
space:
mode:
Diffstat (limited to 'spudec.c')
-rw-r--r--spudec.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/spudec.c b/spudec.c
index 57275b9250..9206695ba6 100644
--- a/spudec.c
+++ b/spudec.c
@@ -506,6 +506,7 @@ void spudec_assemble(void *this, unsigned char *packet_bytes, unsigned int len,
if (last_packet->size < last_packet->offset + len){
mp_msg(MSGT_SPUDEC,MSGL_WARN,"SPUasm: invalid fragment\n");
last_packet->size = last_packet->offset = 0;
+ return;
} else {
memcpy(last_packet->data + last_packet->offset, packet_bytes, len);
last_packet->offset += len;