pub fn shutdown_helper(&mut self) {
        for descriptor in self.descriptors.values() {
            match descriptor {
                CompatDescriptor::New(_) => continue,
                CompatDescriptor::Legacy(d) => unsafe {
                    cshadow::descriptor_shutdownHelper(d.ptr())
                },
            };
        }
    }
/// This is a helper function that handles some corner cases where some
/// descriptors are linked to each other and we must remove that link in
/// order to ensure that the reference count reaches zero and they are properly
/// freed. Otherwise the circular reference will prevent the free operation.
/// TODO: remove this once the TCP layer is better designed.
This is a helper function that handles some corner cases where some
descriptors are linked to each other and we must remove that link in
order to ensure that the reference count reaches zero and they are properly
freed. Otherwise the circular reference will prevent the free operation.
TODO: remove this once the TCP layer is better designed.
This is a helper function that handles some corner cases where some descriptors are linked to each other and we must remove that link in order to ensure that the reference count reaches zero and they are properly freed . Otherwise the circular reference will prevent the free operation . TODO : remove this once the TCP layer is better designed .
pub fn shutdown_helper(&mut self) {
        for descriptor in self.descriptors.values() {
            match descriptor {
                CompatDescriptor::New(_) => continue,
                CompatDescriptor::Legacy(d) => unsafe {
                    cshadow::descriptor_shutdownHelper(d.ptr())
                },
            };
        }
    }
pub fn shutdown_helper ( & mut self ) { for descriptor in self . descriptors . values ( ) { match descriptor { CompatDescriptor :: New ( _ ) => continue , CompatDescriptor :: Legacy ( d ) => unsafe { cshadow :: descriptor_shutdownHelper ( d . ptr ( ) ) } , } ; } }
This is a helper function that handles some corner cases where some
descriptors are linked to each other and we must remove that link in
order to ensure that the reference count reaches zero and they are properly
freed.
This is a helper function that handles some corner cases where some descriptors are linked to each other and we must remove that link in order to ensure that the reference count reaches zero and they are properly freed .
&mut self
&mut self