Lines 1-53
Link Here
|
1 |
--- ffmpeg-strip-wma/asf.c.orig Sun Oct 23 08:03:33 2005 |
|
|
2 |
+++ ffmpeg-strip-wma/asf.c Sun Oct 23 08:03:37 2005 |
3 |
@@ -16,10 +16,13 @@ |
4 |
* License along with this library; if not, write to the Free Software |
5 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
6 |
*/ |
7 |
+ |
8 |
+#if defined(USE_ICONV) |
9 |
+#include <iconv.h> |
10 |
+#endif /* USE_ICONV */ |
11 |
+ |
12 |
#include "avformat.h" |
13 |
#include "avi.h" |
14 |
-//#include "mpegaudio.h" |
15 |
-#include <iconv.h> |
16 |
|
17 |
#undef NDEBUG |
18 |
#include <assert.h> |
19 |
@@ -830,6 +833,7 @@ |
20 |
return str; |
21 |
} |
22 |
|
23 |
+#if defined(USE_ICONV) |
24 |
static void tag_recode(char *before, unsigned int len) |
25 |
{ |
26 |
int result; |
27 |
@@ -842,7 +846,7 @@ |
28 |
unsigned int length = len; |
29 |
|
30 |
memcpy(ansb, before, len); |
31 |
- frt = iconv_open(getlocale(), "UNICODE"); |
32 |
+ frt = iconv_open(getlocale(), "UTF-16LE"); |
33 |
if (frt == (iconv_t) - 1) |
34 |
{ |
35 |
return; |
36 |
@@ -859,6 +863,7 @@ |
37 |
return; |
38 |
return; |
39 |
} |
40 |
+#endif /* USE_ICONV */ |
41 |
|
42 |
static void get_str16_nolen(ByteIOContext *pb, int len, char *buf, int buf_size) |
43 |
{ |
44 |
@@ -873,7 +878,9 @@ |
45 |
*q++ = c; |
46 |
len--; |
47 |
} |
48 |
+#if defined(USE_ICONV) |
49 |
tag_recode(buf, lenz); |
50 |
+#endif /* USE_ICONV */ |
51 |
} |
52 |
|
53 |
static int asf_probe(AVProbeData *pd) |