evpobr
e01ee91591
Fix Clang warnings
2020-09-04 10:03:09 +05:00
Fabian Greffrath
2ccb23fe72
sfe_copy_data_fp: check value of "max" variable for being normal
...
and check elements of the data[] array for being finite.
Both checks use functions provided by the <math.h> header as declared
by the C99 standard.
Fixes #317
CVE-2017-14245
CVE-2017-14246
2020-06-20 18:18:11 +10:00
Arthur Taylor
65e13303ae
sndfile-convert: Handle gsm, vox and opus extensions the same way
...
Closes: https://github.com/erikd/libsndfile/pull/498
2020-04-05 20:07:01 +10:00
Moonbase59
3a57ea117b
Add BWF v2 loudness parameters
...
Closes: https://github.com/erikd/libsndfile/issues/479
2019-08-27 07:28:25 +10:00
Erik de Castro Lopo
25824cb914
sndfile-convert: Close input file on output format error
2019-04-22 02:48:50 +10:00
Erik de Castro Lopo
df55170ce4
sndfile-convert: Fix conversion to/from Opus
2019-04-22 02:48:50 +10:00
Erik de Castro Lopo
238ee50429
programs/sndfile-convert.c: Add -opus option
2019-02-23 18:30:02 +11:00
Marcel Waldvogel
c0dd8b4a4f
Handle snprintf() format-truncation warnings
2019-01-03 15:21:05 +11:00
Brett T. Warden
aaea680337
Check MAX_CHANNELS in sndfile-deinterleave
...
Allocated buffer has space for only 16 channels. Verify that input file
meets this limit.
Fixes #397
2018-08-29 08:20:56 +10:00
Jonathan Wakely
2241075e47
sndfile-convert: Check if conversion failed due to no. of channels
...
This fixes the problem noted in #43 where attempting to convert a stereo
WAV to SDS gives a misleading error about the codec, when the real problem
is that the output format only supports mono not stereo.
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2018-02-03 16:12:42 +11:00
Jan Starý
2acea2723a
sndfile-play: Remove BEOS support
...
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2018-02-03 13:10:10 +11:00
Jan Starý
e6b473ed8e
drop MacOSX from sndfile-play
...
We don't play on MacOSX >= 10.8 (the code for the new API is not written),
and support for MacOSX older than that was removed some time ago.
So drop the last remnants; we just don't play on MacOSX.
2018-02-03 12:54:50 +11:00
Erik de Castro Lopo
203096325d
programs/sndfile-convert.c: Add -float64 conversion
2017-10-14 20:54:56 +11:00
David Seifert
e6c42ff027
Make build system completely non-recursive
2017-09-26 19:35:56 +10:00
Erik de Castro Lopo
e6a1749832
sndfile-deinterleave.c: Check for errors in path handling
...
Closes: https://github.com/erikd/libsndfile/issues/301
2017-07-29 12:08:10 +10:00
Erik de Castro Lopo
5efe93de20
programs/common.c: Fix compiler warning
2017-07-29 12:08:10 +10:00
evpobr
affb1d088d
programs/sndfile-salvage.c: Fix wrong filename in error message
...
Closes : #290
2017-06-14 19:55:37 +10:00
David Seifert
7264aefd09
Use AM_PATH_PYTHON to handle python
...
* AM_PATH_PYTHON is more versatile and allows the
user to specify the python interpreter to use.
2017-06-06 08:19:21 +10:00
Erik de Castro Lopo
d5b785afdd
sndfile-play.c: Fix scaling of float samples with ALSA.
...
Seems ALSA wants float samples in the [-1.0, 1.0] range.
Closes: https://github.com/erikd/libsndfile/issues/275
2017-05-31 20:02:04 +10:00
evpobr
58737ceb48
tests: Fixes for MSVC
...
* src/test_main.c: Fix undeclared off_t type with MSVC
* tests/misc_test.c: Fix undefined S_ISCHR & S_ISBLK with MSVC
* tests/stdin_test.c: Fix undefined STDIN_FILENO with MSVC
* tests/win32_ordinal_test.c: Fix undeclared getcwd() with MSVC
* Fix missing unistd.h under Win32
Related: https://github.com/erikd/libsndfile/issues/154
2017-04-14 13:03:27 +10:00
Erik de Castro Lopo
1c0ea87cc3
Rework CMake build system
...
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2017-04-05 19:38:36 +10:00
David Seifert
c87b8b79a6
Make 'test-sndfile-metadata-set.py' py2/py3 compatible
...
'#!/usr/bin/env python' constructs are more portable, as they
allow the user to override which python executable is called.
See also:
https://blogs.gentoo.org/mgorny/2016/02/08/a-quick-note-on-portable-shebangs/
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2017-01-28 21:16:21 +11:00
David Seifert
1bfb5a908f
Refactor generation of test-suite
...
It's more preferable to generate the testsuite when running 'make dist'
or 'make distcheck' instead of running it from the configure script.
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2017-01-28 21:16:21 +11:00
Erik de Castro Lopo
50a4098e9f
sndfile-play: Remove support for Darwin <= 11
...
Darwin 12 (Mountain Lion) was released in February 2012. Apple no
longer support 11 and neither does libsndfile.
2016-07-03 10:33:31 +10:00
Lars Palo
bda4eb309c
Add cues to sndfile-convert
...
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2016-04-11 19:55:10 +10:00
Erik de Castro Lopo
e8ce824d83
programs/sndfile-cmp.c: Fix cppcheck warning
2016-04-02 19:31:11 +11:00
Erik de Castro Lopo
19d4373c02
programs/sndfile-metadata-set.c: Fix memory leak
...
Found using address sanitizer (ASAN).
2016-04-02 19:29:49 +11:00
Erik de Castro Lopo
afdecb6eab
programs/test-sndfile-metadata-set.py: Print output on failure
2016-04-02 18:52:59 +11:00
Erik de Castro Lopo
563e514f34
programs/: Fix tests when cross compiling from linux to windows
...
When cross-compiling, the programs have a `.exe` file extension.
2016-04-02 18:23:46 +11:00
Erik de Castro Lopo
3663c1b5b5
programs/: Add tests for get/set metadata
2016-04-02 10:33:44 +11:00
Erik de Castro Lopo
bb6cd875af
Remove all mentions of Carbon for OSX
...
Suport for Carbon was remove in 2012, but crept back in the same
year in an un-related commit.
Patch-from: Jan Stary <hans@stare.cz>
2015-11-27 06:16:38 +11:00
Erik de Castro Lopo
e19adf46e1
programs/sndfile-play.c: Fix typo in comment
...
OpenBDS -> OpenBSD
2015-10-29 13:16:50 +11:00
Daniel Winzen
cd838a022e
Fix memory leaks
...
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
Closes: https://github.com/erikd/libsndfile/pull/100
2015-08-07 20:19:24 +10:00
Erik de Castro Lopo
95c6970e6d
sndfile-interleave: Fix handling of last buffer
...
Without this patch the longer of the two files being interleaved
could end up truncated.
Patch-from: Jan Stary <hans@stare.cz>
Reported-by: Josef Kucera <kucerjo3@fit.cvut.cz>
2015-04-27 18:28:40 +10:00
Erik de Castro Lopo
20b7b13d35
programs/ : Minor console output fixes.
...
* programs/common.c : Remove copy/paste cruft.
* programs/sndfile-play.c : Fix inconsistent indentation.
Patch-from: Jan Stary <hans@stare.cz>
2014-11-11 06:13:32 -08:00
Mario Lang
e873283dc3
Fix some typos.
...
Closes: https://github.com/erikd/libsndfile/pull/79
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2014-10-27 06:17:57 +11:00
Erik de Castro Lopo
6ac898c7b6
More fixes for HAVE_SNDIO_H changes.
2014-08-03 19:54:45 +10:00
Erik de Castro Lopo
c161588249
Fix detection and usage OpenBSD's <sndio.h>.
2014-07-30 14:36:47 +10:00
Erik de Castro Lopo
b25f7f3bb3
Revert "src/sndfile.c : Make WAV/GSM610 with sample rates other than 8kHz invalid."
...
Commit was a0be1713b5
.
Also revert the related commits:
* e4253e1609
* 77504d6abd
2014-07-03 21:30:52 +10:00
Erik de Castro Lopo
77504d6abd
programs/sndfile-convert.c : Improve error message for GSM610.
...
Suggested-by: Jan Stary <hans@stare.cz>
2014-07-02 19:47:37 +10:00
Erik de Castro Lopo
bbd4512540
programs/sndfile-convert.c : Add warning for some conversions.
...
Specifically when converting to GSM 6.10 when the input samplerate
is not 8kHz no resampling will be done so when the file is played
it will simply sound like the original input file played at the
new sample rate.
Suggested-by: Jan Stary <hans@stare.cz>
2014-07-01 21:30:12 +10:00
Erik de Castro Lopo
0319ecb91f
Reorder file format lists to be the same as sndfile.h and api.html
...
* Reorders the list of recognized file formats and their filename
extensions and aliases in programs/common.c's format_map[] and in
sndfile-convert.1 so that the list is in the same order as in
sndfile.h and api.html
* Adds more types that we know but format_map[] didn't use, namely
AVR and WAVEX
* Add more filename extension aliases, insipred by those recognized
by SoX, namely "sph" for NIST and "prc" for WVE.
Patch-from: Jan Stary <hans@stare.cz>
2014-07-01 16:51:18 +10:00
Erik de Castro Lopo
9cae6da0b8
programs/*.c : More exit code fixes.
...
Patch-from: Jan Stary <hans@stare.cz>
2014-06-25 06:09:58 +10:00
Erik de Castro Lopo
0291af2be5
programs/sndfile-cmp.c : Fix up exit status.
...
Patch-from: Jan Stary <hans@stare.cz>
2014-06-24 19:33:19 +10:00
Erik de Castro Lopo
15d04a775f
programs/sndfile-metadata-get.c : Make --all the default behaviour.
...
If given a file name without any options, just behave as if it had
been given the --all option.
Suggested-by: Jan Stary <hans@stare.cz>
2014-06-24 10:32:03 +10:00
Erik de Castro Lopo
21cfbcc491
programs/sndfile-metadata-*.c : Minor cleanup.
...
Patch-from: Jan Stary <hans@stare.cz>
2014-06-23 17:17:55 +10:00
Erik de Castro Lopo
c1a09a5065
programs/*.c : Clean up and normailize printing of version strings.
...
Suggested-by: Jan Stary <hans@stare.cz>
2014-06-23 17:17:51 +10:00
Erik de Castro Lopo
7f08ad877b
programs/sndfile-convert.c : Clean up --help output.
...
Patch-from: Jan Stary <hans@stare.cz>
2014-06-21 19:05:03 +10:00
Erik de Castro Lopo
e5e6ff5a0d
programs/sndfile-play.c : Special case for Android.
...
Actual playback is not supported but at least it now compiles for Android.
2013-07-31 18:32:18 +10:00
Erik de Castro Lopo
409d05275f
programs/sndfile-convert.c : Add a -normalize command line argument.
...
Feature request by Tim Blechmann.
Closes : https://github.com/erikd/libsndfile/issues/23
2013-07-02 17:48:50 +10:00