4 ms·
Windows handles can be handles to a number of different types of objects. Generic operations which can be performed for any type of handle: * Closing the handl
by useerup 8y ago
Windows handles can be handles to a number of different types of objects. Generic operations which can be performed for any type of handle:
* Closing the handle: Release any kernel resources associated with the the handle
* Comparing to other handles
* Duplicating, e.g. duplicating a handle to be used by another process. This allow a process to create a less privileged process and only pass handles with certain privileges to the process.
* Get/set handle flags, e-g- flag which indicates whether the handle will be inherited by child processes.
For each object type a number of object type specific operations can be used in addition to the above, e.g. file read/write for files or send/receive for sockets.
Regardless of whether a handle is for a file, a socket, window, mutex or something else, the generic functions such as close will always work.