Skip to content

Commit

Permalink
Release file descriptor even when releasing of android muxer fails (#274
Browse files Browse the repository at this point in the history
)
  • Loading branch information
vamshi-dhulipala authored Apr 26, 2024
1 parent 2c73c71 commit e32b6fd
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -146,8 +146,11 @@ public void writeSampleData(int targetTrack, @NonNull ByteBuffer buffer, @NonNul

@Override
public void release() {
mediaMuxer.release();
releaseFileDescriptor();
try {
mediaMuxer.release();
} finally {
releaseFileDescriptor();
}
}

@Override
Expand Down

0 comments on commit e32b6fd

Please sign in to comment.