aboutsummaryrefslogtreecommitdiffstats
path: root/main/audacious-plugins/audacious-plugins-2.5.1-vorbis.patch
blob: 0e35adff3d3e73b14a5089f84846bdc58c652922 (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
42
43
44
45
46
47
48
49
50
51
52
53
54
From 6ed2a39924b29f185e5a87bd8dccffaa0f1011ca Mon Sep 17 00:00:00 2001
From: John Lindgren <john.lindgren@tds.net>
Date: Wed, 08 Jun 2011 18:49:57 +0000
Subject: vorbis: Patch from Michael Schwendt to fix crash on 32-bit systems.  Closes: AUDPLUG-369.

---
diff --git a/src/vorbis/vcedit.c b/src/vorbis/vcedit.c
index 9dd6c01..dc14d2f 100644
--- a/src/vorbis/vcedit.c
+++ b/src/vorbis/vcedit.c
@@ -145,7 +145,7 @@ _fetch_next_packet(vcedit_state * s, ogg_packet * p, ogg_page * page)
 {
     int result;
     char *buffer;
-    int bytes;
+    gint64 bytes;
 
     result = ogg_stream_packetout(s->os, p);
 
@@ -189,7 +189,7 @@ vcedit_open_callbacks(vcedit_state * state, void *in,
                       vcedit_write_func write_func)
 {
     char *buffer;
-    int bytes, i;
+    gint64 bytes, i;
     ogg_packet *header;
     ogg_packet header_main;
     ogg_packet header_comments;
@@ -317,7 +317,7 @@ vcedit_write(vcedit_state * state, void *out)
     ogg_int64_t granpos = 0;
     int result;
     char *buffer;
-    int bytes;
+    gint64 bytes;
     int needflush = 0, needout = 0;
 
     state->eosin = 0;
diff --git a/src/vorbis/vcedit.h b/src/vorbis/vcedit.h
index 983a2ee..ea4432f 100644
--- a/src/vorbis/vcedit.h
+++ b/src/vorbis/vcedit.h
@@ -19,8 +19,8 @@ extern "C" {
 #include <vorbis/codec.h>
 #include <audacious/plugin.h>
 
-typedef size_t (*vcedit_read_func)(void *, size_t, size_t, void *);
-typedef size_t (*vcedit_write_func)(const void *, size_t, size_t, void *);
+typedef gint64 (*vcedit_read_func)(void *, gint64, gint64, void *);
+typedef gint64 (*vcedit_write_func)(const void *, gint64, gint64, void *);
 
 typedef struct {
 	ogg_sync_state	 *oy;
--
cgit v0.8.3.4