mirror of
https://github.com/claunia/flac.git
synced 2025-12-16 18:54:26 +00:00
Memory and fd leak fixes - ID: 3436668
http://sourceforge.net/tracker/?func=detail&aid=3436668&group_id=13478&atid=313478
This commit is contained in:
@@ -352,8 +352,10 @@ static bool write_chain_(FLAC::Metadata::Chain &chain, bool use_padding, bool pr
|
||||
FILE *file = fopen(filename, "r+b");
|
||||
if(0 == file)
|
||||
return false; /*@@@@ chain status still says OK though */
|
||||
if(!chain.write(use_padding, (::FLAC__IOHandle)file, callbacks))
|
||||
if(!chain.write(use_padding, (::FLAC__IOHandle)file, callbacks)) {
|
||||
fclose(file);
|
||||
return false;
|
||||
}
|
||||
fclose(file);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user