mirror of
https://gitee.com/openharmony/third_party_libsnd
synced 2024-11-23 09:59:54 +00:00
src/alac.c : Make sure temp file gets opened in binary mode.
This commit is contained in:
parent
a53b8479f3
commit
542ef9fa49
@ -1,3 +1,8 @@
|
|||||||
|
2012-02-06 Erik de Castro Lopo <erikd AT mega-nerd DOT com>
|
||||||
|
|
||||||
|
* src/alac.c
|
||||||
|
Make sure temp file gets opened in binary mode.
|
||||||
|
|
||||||
2012-02-05 Erik de Castro Lopo <erikd AT mega-nerd DOT com>
|
2012-02-05 Erik de Castro Lopo <erikd AT mega-nerd DOT com>
|
||||||
|
|
||||||
* src/
|
* src/
|
||||||
|
@ -336,7 +336,7 @@ alac_writer_init (SF_PRIVATE *psf)
|
|||||||
return SFE_NO_TEMP_DIR ;
|
return SFE_NO_TEMP_DIR ;
|
||||||
|
|
||||||
snprintf (plac->enctmpname, sizeof (plac->enctmpname), "%s/%x%x.alac", tmpdir, psf_rand_int32 (), psf_rand_int32 ()) ;
|
snprintf (plac->enctmpname, sizeof (plac->enctmpname), "%s/%x%x.alac", tmpdir, psf_rand_int32 (), psf_rand_int32 ()) ;
|
||||||
if ((plac->enctmp = fopen (plac->enctmpname, "w+")) == NULL)
|
if ((plac->enctmp = fopen (plac->enctmpname, "wb+")) == NULL)
|
||||||
return SFE_ALAC_FAIL_TMPFILE ;
|
return SFE_ALAC_FAIL_TMPFILE ;
|
||||||
|
|
||||||
alac_encoder_init (&plac->encoder, psf->sf.samplerate, psf->sf.channels, alac_format_flags, ALAC_FRAME_LENGTH) ;
|
alac_encoder_init (&plac->encoder, psf->sf.samplerate, psf->sf.channels, alac_format_flags, ALAC_FRAME_LENGTH) ;
|
||||||
|
Loading…
Reference in New Issue
Block a user