mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-22 09:31:06 +00:00
Remove now unnecessary Send+Sync
impls for element/etc subclasses
This is now automatically implemented.
This commit is contained in:
parent
319f1c68a5
commit
0f22eb7633
5 changed files with 0 additions and 31 deletions
|
@ -150,10 +150,6 @@ mod media_factory {
|
||||||
pub struct Factory(ObjectSubclass<imp::Factory>) @extends gst_rtsp_server::RTSPMediaFactory;
|
pub struct Factory(ObjectSubclass<imp::Factory>) @extends gst_rtsp_server::RTSPMediaFactory;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Factories must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for Factory {}
|
|
||||||
unsafe impl Sync for Factory {}
|
|
||||||
|
|
||||||
impl Default for Factory {
|
impl Default for Factory {
|
||||||
// Creates a new instance of our factory
|
// Creates a new instance of our factory
|
||||||
fn default() -> Factory {
|
fn default() -> Factory {
|
||||||
|
@ -209,10 +205,6 @@ mod media {
|
||||||
glib::wrapper! {
|
glib::wrapper! {
|
||||||
pub struct Media(ObjectSubclass<imp::Media>) @extends gst_rtsp_server::RTSPMedia;
|
pub struct Media(ObjectSubclass<imp::Media>) @extends gst_rtsp_server::RTSPMedia;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Medias must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for Media {}
|
|
||||||
unsafe impl Sync for Media {}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Our custom RTSP server subclass that reports when clients are connecting and uses
|
// Our custom RTSP server subclass that reports when clients are connecting and uses
|
||||||
|
@ -270,10 +262,6 @@ mod server {
|
||||||
pub struct Server(ObjectSubclass<imp::Server>) @extends gst_rtsp_server::RTSPServer;
|
pub struct Server(ObjectSubclass<imp::Server>) @extends gst_rtsp_server::RTSPServer;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Servers must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for Server {}
|
|
||||||
unsafe impl Sync for Server {}
|
|
||||||
|
|
||||||
impl Default for Server {
|
impl Default for Server {
|
||||||
// Creates a new instance of our factory
|
// Creates a new instance of our factory
|
||||||
fn default() -> Server {
|
fn default() -> Server {
|
||||||
|
@ -322,10 +310,6 @@ mod client {
|
||||||
pub struct Client(ObjectSubclass<imp::Client>) @extends gst_rtsp_server::RTSPClient;
|
pub struct Client(ObjectSubclass<imp::Client>) @extends gst_rtsp_server::RTSPClient;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Clients must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for Client {}
|
|
||||||
unsafe impl Sync for Client {}
|
|
||||||
|
|
||||||
impl Default for Client {
|
impl Default for Client {
|
||||||
// Creates a new instance of our factory
|
// Creates a new instance of our factory
|
||||||
fn default() -> Client {
|
fn default() -> Client {
|
||||||
|
@ -374,10 +358,6 @@ mod mount_points {
|
||||||
pub struct MountPoints(ObjectSubclass<imp::MountPoints>) @extends gst_rtsp_server::RTSPMountPoints;
|
pub struct MountPoints(ObjectSubclass<imp::MountPoints>) @extends gst_rtsp_server::RTSPMountPoints;
|
||||||
}
|
}
|
||||||
|
|
||||||
// MountPoints must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for MountPoints {}
|
|
||||||
unsafe impl Sync for MountPoints {}
|
|
||||||
|
|
||||||
impl Default for MountPoints {
|
impl Default for MountPoints {
|
||||||
// Creates a new instance of our factory
|
// Creates a new instance of our factory
|
||||||
fn default() -> Self {
|
fn default() -> Self {
|
||||||
|
|
|
@ -220,10 +220,6 @@ mod fir_filter {
|
||||||
pub struct FirFilter(ObjectSubclass<imp::FirFilter>) @extends gst_base::BaseTransform, gst::Element, gst::Object;
|
pub struct FirFilter(ObjectSubclass<imp::FirFilter>) @extends gst_base::BaseTransform, gst::Element, gst::Object;
|
||||||
}
|
}
|
||||||
|
|
||||||
// GStreamer elements must be Send+Sync, and ours is
|
|
||||||
unsafe impl Send for FirFilter {}
|
|
||||||
unsafe impl Sync for FirFilter {}
|
|
||||||
|
|
||||||
impl FirFilter {
|
impl FirFilter {
|
||||||
// Creates a new instance of our filter with the given name
|
// Creates a new instance of our filter with the given name
|
||||||
pub fn new(name: Option<&str>) -> FirFilter {
|
pub fn new(name: Option<&str>) -> FirFilter {
|
||||||
|
|
|
@ -545,7 +545,6 @@ mod tests {
|
||||||
const NAME: &'static str = "TestBufferPool";
|
const NAME: &'static str = "TestBufferPool";
|
||||||
type Type = super::TestBufferPool;
|
type Type = super::TestBufferPool;
|
||||||
type ParentType = BufferPool;
|
type ParentType = BufferPool;
|
||||||
type Interfaces = ();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -780,9 +780,6 @@ mod tests {
|
||||||
pub struct TestElement(ObjectSubclass<imp::TestElement>) @extends Element, crate::Object;
|
pub struct TestElement(ObjectSubclass<imp::TestElement>) @extends Element, crate::Object;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsafe impl Send for TestElement {}
|
|
||||||
unsafe impl Sync for TestElement {}
|
|
||||||
|
|
||||||
impl TestElement {
|
impl TestElement {
|
||||||
pub fn new(name: Option<&str>) -> Self {
|
pub fn new(name: Option<&str>) -> Self {
|
||||||
glib::Object::new(&[("name", &name)]).unwrap()
|
glib::Object::new(&[("name", &name)]).unwrap()
|
||||||
|
|
|
@ -129,9 +129,6 @@ mod tests {
|
||||||
pub struct TestPad(ObjectSubclass<imp::TestPad>) @extends Pad, crate::Object;
|
pub struct TestPad(ObjectSubclass<imp::TestPad>) @extends Pad, crate::Object;
|
||||||
}
|
}
|
||||||
|
|
||||||
unsafe impl Send for TestPad {}
|
|
||||||
unsafe impl Sync for TestPad {}
|
|
||||||
|
|
||||||
impl TestPad {
|
impl TestPad {
|
||||||
pub fn new(name: &str, direction: PadDirection) -> Self {
|
pub fn new(name: &str, direction: PadDirection) -> Self {
|
||||||
glib::Object::new(&[("name", &name), ("direction", &direction)]).unwrap()
|
glib::Object::new(&[("name", &name), ("direction", &direction)]).unwrap()
|
||||||
|
|
Loading…
Reference in a new issue