diff options
Diffstat (limited to 'apps/codecs/aiff_enc.c')
-rw-r--r-- | apps/codecs/aiff_enc.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/codecs/aiff_enc.c b/apps/codecs/aiff_enc.c index 2292bcc275..51c4344702 100644 --- a/apps/codecs/aiff_enc.c +++ b/apps/codecs/aiff_enc.c | |||
@@ -181,13 +181,12 @@ static bool on_end_file(struct enc_file_event_data *data) | |||
181 | hdr.ssnd_size = htobe32(data_size + 8); | 181 | hdr.ssnd_size = htobe32(data_size + 8); |
182 | 182 | ||
183 | if (ci->lseek(data->rec_file, 0, SEEK_SET) != 0 || | 183 | if (ci->lseek(data->rec_file, 0, SEEK_SET) != 0 || |
184 | ci->write(data->rec_file, &hdr, sizeof (hdr)) != sizeof (hdr)) | 184 | ci->write(data->rec_file, &hdr, sizeof (hdr)) != sizeof (hdr) || |
185 | ci->close(data->rec_file) != 0) | ||
185 | { | 186 | { |
186 | return false; | 187 | return false; |
187 | } | 188 | } |
188 | 189 | ||
189 | ci->fsync(data->rec_file); | ||
190 | ci->close(data->rec_file); | ||
191 | data->rec_file = -1; | 190 | data->rec_file = -1; |
192 | 191 | ||
193 | return true; | 192 | return true; |