|
@@ -1,24 +1,11 @@
|
1
|
1
|
--- a/src/lib/alac/alac.c
|
2
|
2
|
+++ b/src/lib/alac/alac.c
|
3
|
|
-@@ -29,11 +29,7 @@
|
|
3
|
+@@ -29,7 +29,7 @@
|
4
|
4
|
*
|
5
|
5
|
*/
|
6
|
6
|
|
7
|
|
--#ifdef __BIG_ENDIAN__
|
8
|
|
--static const int host_bigendian = 1;
|
9
|
|
--#else
|
10
|
7
|
-static const int host_bigendian = 0;
|
11
|
|
--#endif
|
12
|
|
-+static int host_bigendian = 0;
|
|
8
|
++#define host_bigendian (htonl(42) == 42)
|
13
|
9
|
|
14
|
10
|
#include <stdio.h>
|
15
|
11
|
#include <stdlib.h>
|
16
|
|
-@@ -1181,6 +1177,8 @@ alac_file *create_alac(int samplesize, i
|
17
|
|
- {
|
18
|
|
- alac_file *newfile = malloc(sizeof(alac_file));
|
19
|
|
-
|
20
|
|
-+ host_bigendian = (htonl(42) == 42);
|
21
|
|
-+
|
22
|
|
- newfile->samplesize = samplesize;
|
23
|
|
- newfile->numchannels = numchannels;
|
24
|
|
- newfile->bytespersample = (samplesize / 8) * numchannels;
|