Eryk Sun <eryk...@gmail.com> added the comment:

> In Windows there is an fast API to copy file in kernel mode: CopyFile

The possibility of calling CopyFileEx() for shutil.copy2() is discussed in 
issue 30044. Note that CopyFileEx() is a high-level Windows API function, not a 
"kernel mode" copy. It opens the source and destination files and makes 
multiple system calls in order to copy file data and metadata (e.g. system 
calls such as NtOpenFile, NtCreateFile, NtReadFile, NtWriteFile, 
NtQueryInformationFile, NtSetInformationFile, NtQueryEaFile, NtSetEaFile, 
NtQuerySecurityObject, etc). This includes copying the primary data stream, 
alternate data streams, file attributes, extended file attributes, and security 
resource attributes.

----------
components:  -Windows
nosy: +eryksun

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue44579>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to