From c5c9fe325782a790d563a0a8b1cf62a855a50d81 Mon Sep 17 00:00:00 2001 From: Helmut Grohne Date: Sat, 25 May 2024 10:22:21 +0200 Subject: add a FileDescriptor type It serves two main purposes. For one thing, it allows telling bare integers and file descriptors apart on a typing level similar to a NewType. For another it adds common methods to a file descriptor and enables closing it via a context manager. --- linuxnamespaces/__init__.py | 1 + 1 file changed, 1 insertion(+) (limited to 'linuxnamespaces/__init__.py') diff --git a/linuxnamespaces/__init__.py b/linuxnamespaces/__init__.py index 3302867..b50f113 100644 --- a/linuxnamespaces/__init__.py +++ b/linuxnamespaces/__init__.py @@ -16,6 +16,7 @@ import stat import subprocess import typing +from .filedescriptor import FileDescriptor from .atlocation import * from .syscalls import * -- cgit v1.2.3