Those dups are handled by the kernel already by creating a new reference to the underlying file descriptor.