filter/source: add flush() method

This commit is contained in:
lummax 2015-09-19 11:47:02 +02:00 committed by meh
parent fc6c0755ef
commit 4471ffc934

View File

@ -1,3 +1,5 @@
use std::ptr;
use ffi::*;
use ::{Error, Frame};
use super::Context;
@ -27,4 +29,10 @@ impl<'a> Source<'a> {
}
}
}
pub fn flush(&mut self) -> Result<(), Error> {
unsafe {
self.add(&Frame::wrap(ptr::null_mut()))
}
}
}