When operating on external provided file descriptors it would be useful if it was possible to create a Memfd that does not
take ownership of the file descriptor.
For example in a graphics pipeline the file descriptor is transported in a separate structure that has the ownership of the
file descriptor. Within the pipeline a filter wants to operate on the file descriptor using Memfd.
impl Filter for GraphicsPipeline {
fn filter(&self, memory: &Memory) -> Result<(), Error> {
let mfd = Memfd::try_borrow_from(memory.fd())?;
...
}
}