do not close parcel file descriptor fd twice
This commit is contained in:
parent
457b0fb1b1
commit
4e8aafae76
|
@ -91,9 +91,8 @@ static AVIOContext *create_fd_avio_context(const char *filename, int flags) {
|
|||
static void close_fd_avio_context(AVIOContext *ctx) {
|
||||
if (fd_seek(ctx->opaque, 0, AVSEEK_SIZE) >= 0) {
|
||||
int *fd = ctx->opaque;
|
||||
close(*fd);
|
||||
closeParcelFileDescriptor(*fd);
|
||||
av_freep(fd);
|
||||
av_freep(&fd);
|
||||
}
|
||||
ctx->opaque = NULL;
|
||||
}
|
||||
|
|
|
@ -979,7 +979,7 @@ public class FFmpegKitConfig {
|
|||
pfdMap.delete(fd);
|
||||
}
|
||||
} catch (final Throwable t) {
|
||||
android.util.Log.e(TAG, String.format("Failed to close file descriptor %d.%s", fd, Exceptions.getStackTraceString(t)));
|
||||
android.util.Log.e(TAG, String.format("Failed to close file descriptor: %d.%s", fd, Exceptions.getStackTraceString(t)));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user