format/context: implement DerefMut
This commit is contained in:
parent
547ea2829e
commit
82ab89d1bf
@ -2,7 +2,7 @@ use std::ffi::CString;
|
||||
use std::ptr;
|
||||
use std::path::Path;
|
||||
use std::marker::PhantomData;
|
||||
use std::ops::Deref;
|
||||
use std::ops::{Deref, DerefMut};
|
||||
|
||||
use libc::c_uint;
|
||||
use ffi::*;
|
||||
@ -183,6 +183,12 @@ impl<'a> Deref for Packet<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> DerefMut for Packet<'a> {
|
||||
fn deref_mut<'b>(&'b mut self) -> &'b mut ::Packet {
|
||||
&mut self.pkt
|
||||
}
|
||||
}
|
||||
|
||||
pub struct StreamIter<'a> {
|
||||
ptr: *const AVFormatContext,
|
||||
cur: c_uint,
|
||||
|
Loading…
x
Reference in New Issue
Block a user