Explorar o código

Fix double close

Accidentally made file references not count as references and therefore also close the fd. My bad.
jD91mZM2 %!s(int64=6) %!d(string=hai) anos
pai
achega
028378b8bf
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/fs.rs

+ 1 - 1
src/fs.rs

@@ -68,7 +68,7 @@ impl File {
     pub unsafe fn get_ref(&self) -> Self {
         Self {
             fd: self.fd,
-            reference: false
+            reference: true
         }
     }
 }