diff options
author | Mark Harris <mark.hsj@gmail.com> | 2018-07-22 03:55:24 +0300 |
---|---|---|
committer | Mark Harris <mark.hsj@gmail.com> | 2018-07-22 07:35:39 +0300 |
commit | 01b035f8ba4f48e9e1ad9f9407f77ce9a7e4aa44 (patch) | |
tree | 650ba740211d9f62460076d6fea50c29d839758e /src/mapping_matrix.c | |
parent | c1c247d7e715100a50ca185948c7336bdd4dfdba (diff) |
Silence compiler warnings
clang -Wcast-align warnings with ambisonics enabled
clang -Wnull-pointer-arithmetic warnings in test_opus_api.c
gcc -Wimplicit-fallthrough warnings on arm
msvc warning C4244 in celt_encoder.c with fixed point
Diffstat (limited to 'src/mapping_matrix.c')
-rw-r--r-- | src/mapping_matrix.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mapping_matrix.c b/src/mapping_matrix.c index 11a14ce1..f9821f7e 100644 --- a/src/mapping_matrix.c +++ b/src/mapping_matrix.c @@ -58,7 +58,8 @@ opus_int32 mapping_matrix_get_size(int rows, int cols) opus_int16 *mapping_matrix_get_data(const MappingMatrix *matrix) { - return (opus_int16*)((char*)matrix + align(sizeof(MappingMatrix))); + /* void* cast avoids clang -Wcast-align warning */ + return (opus_int16*)(void*)((char*)matrix + align(sizeof(MappingMatrix))); } void mapping_matrix_init(MappingMatrix * const matrix, |