python-texttable: update to 1.3.1
[void-packages.git] / srcpkgs / moc / patches / move-pcm-buffer-to-heap.patch
blobd131b1b172dfdfbb3665ad4a837cb4a67638a869
1 --- player.c 2018-02-10 23:53:38.627091352 +0100
2 +++ player.c 2018-02-10 23:54:46.672519217 +0100
3 @@ -444,7 +444,7 @@
5 bool eof = false;
6 bool stopped = false;
7 - char buf[PCM_BUF_SIZE];
8 + char *const buf = xmalloc (PCM_BUF_SIZE);
9 int decoded = 0;
10 struct sound_params new_sound_params;
11 bool sound_params_change = false;
12 @@ -486,7 +486,7 @@
13 status_msg ("Playing...");
16 - decoded = f->decode (decoder_data, buf, sizeof(buf),
17 + decoded = f->decode (decoder_data, buf, PCM_BUF_SIZE,
18 &new_sound_params);
20 if (decoded)
21 @@ -629,6 +629,7 @@
22 precache.f->close (precache.decoder_data);
23 precache_reset (&precache);
25 + free (buf);
28 #if !defined(NDEBUG) && defined(DEBUG)