summaryrefslogtreecommitdiffhomepage
path: root/patches/libmp3splt/CVE-2017-15185.patch
blob: 82090f430069f79e95b022cfe645a9c090d657f1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
diff --git a/plugins/ogg.c b/plugins/ogg.c
index 50cc495..57745f1 100644
--- a/plugins/ogg.c
+++ b/plugins/ogg.c
@@ -212,26 +212,36 @@ static splt_ogg_state *splt_ogg_v_new(int *error)
     goto error;
   }
   memset(oggstate, 0, sizeof(splt_ogg_state));
+
   if ((oggstate->sync_in = malloc(sizeof(ogg_sync_state)))==NULL)
   {
     goto error;
   }
+  memset(oggstate->sync_in, 0, sizeof(ogg_sync_state));
+
   if ((oggstate->stream_in = malloc(sizeof(ogg_stream_state)))==NULL)
   {
     goto error;
   }
+  memset(oggstate->stream_in, 0, sizeof(ogg_stream_state));
+
   if ((oggstate->vd = malloc(sizeof(vorbis_dsp_state)))==NULL)
   {
     goto error;
   }
+  memset(oggstate->vd, 0, sizeof(vorbis_dsp_state));
+
   if ((oggstate->vi = malloc(sizeof(vorbis_info)))==NULL)
   {
     goto error;
   }
+  memset(oggstate->vi, 0, sizeof(vorbis_info));
+
   if ((oggstate->vb = malloc(sizeof(vorbis_block)))==NULL)
   {
     goto error;
   }
+  memset(oggstate->vb, 0, sizeof(vorbis_block));
 
   if ((oggstate->headers = malloc(sizeof(splt_v_packet) * TOTAL_HEADER_PACKETS))==NULL)
   {