1b815c7f3Sopenharmony_ci# Changelog
2b815c7f3Sopenharmony_ci
3b815c7f3Sopenharmony_ciAll notable changes to this project will be documented in this file.
4b815c7f3Sopenharmony_ci
5b815c7f3Sopenharmony_ciThe format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6b815c7f3Sopenharmony_ciand this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7b815c7f3Sopenharmony_ci
8b815c7f3Sopenharmony_ci## [1.2.0] - 2022-12-25
9b815c7f3Sopenharmony_ci
10b815c7f3Sopenharmony_ci### Fixed
11b815c7f3Sopenharmony_ci
12b815c7f3Sopenharmony_ci* Searching for LAME dependency with CMake build system (issue #821).
13b815c7f3Sopenharmony_ci* CMake build from Autotools tarball (issue #816).
14b815c7f3Sopenharmony_ci* Build on UWP platform (issue #824).
15b815c7f3Sopenharmony_ci* Fix signed integer overflow (issue #785).
16b815c7f3Sopenharmony_ci* Skipping large wav chunks on stdin (PR #819).
17b815c7f3Sopenharmony_ci
18b815c7f3Sopenharmony_ci### Removed
19b815c7f3Sopenharmony_ci
20b815c7f3Sopenharmony_ci* Maximum samplerate limit, thanks @drmpeg, @justacec (issue #850).
21b815c7f3Sopenharmony_ci  
22b815c7f3Sopenharmony_ci  In version 1.1.0, an artificial limit of 655350 Hz was created, but as it
23b815c7f3Sopenharmony_ci  turned out, this is not enough for some scenarios.
24b815c7f3Sopenharmony_ci
25b815c7f3Sopenharmony_ci## [1.1.0] - 2022-03-27
26b815c7f3Sopenharmony_ci
27b815c7f3Sopenharmony_ci### Added
28b815c7f3Sopenharmony_ci
29b815c7f3Sopenharmony_ci* MPEG Encode/Decode Support.
30b815c7f3Sopenharmony_ci
31b815c7f3Sopenharmony_ci  Uses libmpg123 for decode, liblame for encode. Encoding and decoding support
32b815c7f3Sopenharmony_ci  is independent of each other and is split into separate files. MPEG support
33b815c7f3Sopenharmony_ci  is generalized as subformats, `SF_FORMAT_MPEG_LAYER`(I,II,III) so that it
34b815c7f3Sopenharmony_ci  might be used by other containers (`MPEG1WAVEFORMAT` for example), but also
35b815c7f3Sopenharmony_ci  contains a major format `SF_FORMAT_MPEG` for 'mp3 files.'
36b815c7f3Sopenharmony_ci
37b815c7f3Sopenharmony_ci  Encoding Status:
38b815c7f3Sopenharmony_ci  * Layer III encoding
39b815c7f3Sopenharmony_ci  * ID3v1 writing
40b815c7f3Sopenharmony_ci  * ID3v2 writing
41b815c7f3Sopenharmony_ci  * Lame/Xing Tag writing
42b815c7f3Sopenharmony_ci  * Bitrate selection command
43b815c7f3Sopenharmony_ci  * VBR or CBR
44b815c7f3Sopenharmony_ci  
45b815c7f3Sopenharmony_ci  Decoding Status:
46b815c7f3Sopenharmony_ci  * Layers I/II/III decoding
47b815c7f3Sopenharmony_ci  * ID3v1 reading
48b815c7f3Sopenharmony_ci  * ID3v2 reading
49b815c7f3Sopenharmony_ci  * Seeking
50b815c7f3Sopenharmony_ci* New fuzzer for OSS-Fuzz, thanks @DavidKorczynski.
51b815c7f3Sopenharmony_ci* This `CHANGELOG.md`. All notable changes to this project will be documented in
52b815c7f3Sopenharmony_ci  this file. The old `NEWS` file has been renamed to `NEWS.OLD` and is no longer
53b815c7f3Sopenharmony_ci  updated.
54b815c7f3Sopenharmony_ci* Add support for decoding MPEG III Audio in WAV files.
55b815c7f3Sopenharmony_ci* `SECURITY.md` file to give people instructions for reporting security
56b815c7f3Sopenharmony_ci  vulnerabilities, thanks @zidingz.
57b815c7f3Sopenharmony_ci* Support for [Vcpkg manifest mode](https://vcpkg.readthedocs.io/en/latest/users/manifests/).
58b815c7f3Sopenharmony_ci
59b815c7f3Sopenharmony_ci  If you have problems with manifest mode, disable it with `VCPKG_MANIFEST_MODE`
60b815c7f3Sopenharmony_ci  switch.
61b815c7f3Sopenharmony_ci* [Export CMake targets from the build tree (PR #802)](https://cmake.org/cmake/help/latest/guide/importing-exporting/index.html#exporting-targets-from-the-build-tree)
62b815c7f3Sopenharmony_ci* CIFuzz fuzzer, thanks to @AdamKorcz (PR #796)
63b815c7f3Sopenharmony_ci
64b815c7f3Sopenharmony_ci### Changed
65b815c7f3Sopenharmony_ci
66b815c7f3Sopenharmony_ci* `SFC_SET_DITHER_ON_READ` and `SFC_SET_DITHER_ON_WRITE` enums comments in
67b815c7f3Sopenharmony_ci  public header, thanks @SmiVan (issue #677).
68b815c7f3Sopenharmony_ci* `ENABLE_SNDFILE_WINDOWS_PROTOTYPES` define is deprecated and not needed
69b815c7f3Sopenharmony_ci  anymore.
70b815c7f3Sopenharmony_ci
71b815c7f3Sopenharmony_ci  Previously, in order for the [`sf_wchar_open`()](http://libsndfile.github.io/libsndfile/api.html#open)
72b815c7f3Sopenharmony_ci  function to become available on   the Windows platform, it was required to
73b815c7f3Sopenharmony_ci  perform certain actions:
74b815c7f3Sopenharmony_ci
75b815c7f3Sopenharmony_ci  ```c
76b815c7f3Sopenharmony_ci  #include <windows.h>
77b815c7f3Sopenharmony_ci  #define ENABLE_SNDFILE_WINDOWS_PROTOTYPES 1
78b815c7f3Sopenharmony_ci  #including <sndfile.h>
79b815c7f3Sopenharmony_ci  ```
80b815c7f3Sopenharmony_ci
81b815c7f3Sopenharmony_ci  These steps are no longer required and the `sf_wchar_open`() function is
82b815c7f3Sopenharmony_ci  always available on the Windows platform.
83b815c7f3Sopenharmony_ci* Use UTF-8 as internal path encoding on Windows platform.
84b815c7f3Sopenharmony_ci
85b815c7f3Sopenharmony_ci  This is an internal change to unify and simplify the handling of file paths.
86b815c7f3Sopenharmony_ci
87b815c7f3Sopenharmony_ci  On the Windows platform, the file path is always converted to UTF-8 and
88b815c7f3Sopenharmony_ci  converted to UTF-16 only for calls to WinAPI functions.
89b815c7f3Sopenharmony_ci
90b815c7f3Sopenharmony_ci  The behavior of the functions for opening files on other platforms does not
91b815c7f3Sopenharmony_ci  change.
92b815c7f3Sopenharmony_ci* Switch to .xz over .bz2 for release tarballs.
93b815c7f3Sopenharmony_ci* Disable static builds using Autotools by default. If you want static
94b815c7f3Sopenharmony_ci  libraries, pass --enable-static to ./configure
95b815c7f3Sopenharmony_ci
96b815c7f3Sopenharmony_ci### Fixed
97b815c7f3Sopenharmony_ci
98b815c7f3Sopenharmony_ci* Typo in `docs/index.md`.
99b815c7f3Sopenharmony_ci* Typo in `programs/sndfile-convert.c`, thanks @fjl.
100b815c7f3Sopenharmony_ci* Memory leak in `caf_read_header`(), credit to OSS-Fuzz ([issue 30375](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=30375)).
101b815c7f3Sopenharmony_ci* Stack overflow in `guess_file_type`(), thanks @bobsayshilol, credit to
102b815c7f3Sopenharmony_ci  OSS-Fuzz ([issue 29339](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=29339)).
103b815c7f3Sopenharmony_ci* Abort in fuzzer, thanks @bobsayshilol, credit to OSS-Fuzz
104b815c7f3Sopenharmony_ci  ([issue 26257](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=26257)).
105b815c7f3Sopenharmony_ci* Infinite loop in `svx_read_header`(), thanks @bobsayshilol, credit to OSS-Fuzz
106b815c7f3Sopenharmony_ci  ([issue 25442](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25442)).
107b815c7f3Sopenharmony_ci* GCC and Clang pedantic warnings, thanks @bobsayshilol.
108b815c7f3Sopenharmony_ci* Normalisation issue when scaling floating point data to `int` in
109b815c7f3Sopenharmony_ci  `replace_read_f2i`(), thanks @bobsayshilol, (issue #702).
110b815c7f3Sopenharmony_ci* Missing samples when doing a partial read of Ogg file from index till the end
111b815c7f3Sopenharmony_ci  of file, thanks @arthurt (issue #643).
112b815c7f3Sopenharmony_ci* sndfile-salvage: Handle files > 4 GB on Windows OS
113b815c7f3Sopenharmony_ci* Undefined shift in `dyn_get_32bit`(), credit to OSS-Fuzz
114b815c7f3Sopenharmony_ci  ([issue 27366](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=27366)).
115b815c7f3Sopenharmony_ci* Integer overflow in `nms_adpcm_update`(), credit to OSS-Fuzz
116b815c7f3Sopenharmony_ci  ([issue 25522](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25522)).
117b815c7f3Sopenharmony_ci* Integer overflow in `psf_log_printf`(), credit to OSS-Fuzz
118b815c7f3Sopenharmony_ci  ([issue 28441](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=28441)),
119b815c7f3Sopenharmony_ci  ([issue 25624](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25624)).
120b815c7f3Sopenharmony_ci* ABI version incompatibility between Autotools and CMake build on Apple
121b815c7f3Sopenharmony_ci  platforms.
122b815c7f3Sopenharmony_ci
123b815c7f3Sopenharmony_ci  Now ABI must be compatible with Autotools builds. Note that this change
124b815c7f3Sopenharmony_ci  requires CMake >= 3.17 for building dylib on Apple platforms.
125b815c7f3Sopenharmony_ci
126b815c7f3Sopenharmony_ci* Fix build with Autotools + MinGW toolchain on Windows platform.
127b815c7f3Sopenharmony_ci
128b815c7f3Sopenharmony_ci  See https://github.com/msys2/MINGW-packages/issues/5803 for details.
129b815c7f3Sopenharmony_ci
130b815c7f3Sopenharmony_ci### Security
131b815c7f3Sopenharmony_ci
132b815c7f3Sopenharmony_ci* Heap buffer overflow in `wavlike_ima_decode_block`(), thanks @bobsayshilol,
133b815c7f3Sopenharmony_ci  credit to OSS-Fuzz ([issue 25530](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25530)).
134b815c7f3Sopenharmony_ci* Heap buffer overflow in `msadpcm_decode_block`(), thanks @bobsayshilol,
135b815c7f3Sopenharmony_ci  credit to OSS-Fuzz ([issue 26803](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=26803)).
136b815c7f3Sopenharmony_ci* Heap buffer overflow in `psf_binheader_readf`(), thanks @bobsayshilol,
137b815c7f3Sopenharmony_ci  credit to OSS-Fuzz ([issue 26026](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=26026)).
138b815c7f3Sopenharmony_ci* Index out of bounds in `psf_nms_adpcm_decode_block`(), credit to OSS-Fuzz
139b815c7f3Sopenharmony_ci  ([issue 25561](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25561)).
140b815c7f3Sopenharmony_ci* Heap buffer overflow in `flac_buffer_copy`(), thanks @yuawn,  @bobsayshilol.
141b815c7f3Sopenharmony_ci* Heap buffer overflow in `copyPredictorTo24`(), thanks @bobsayshilol,
142b815c7f3Sopenharmony_ci  credit to OSS-Fuzz ([issue 27503](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=27503)).
143b815c7f3Sopenharmony_ci* Uninitialized variable in `psf_binheader_readf`(), thanks @shao-hua-li,
144b815c7f3Sopenharmony_ci  credit to OSS-Fuzz ([issue 25364](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25364)).
145b815c7f3Sopenharmony_ci
146b815c7f3Sopenharmony_ci[Unreleased]: https://github.com/libsndfile/libsndfile/compare/1.1.0...HEAD
147b815c7f3Sopenharmony_ci[1.1.0]: https://github.com/libsndfile/libsndfile/compare/1.0.31...1.1.0
148