Programming/C Win32 MFC2008. 12. 30. 00:48
open이 있으면 close가 있는 법. 레지스트리 역시 open / create를 했으면 close를 해주어야 한다.
hKey [in]

A handle to the open key to be closed. The handle must have been opened by the RegCreateKeyEx, RegCreateKeyTransacted, RegOpenKeyEx, RegOpenKeyTransacted, or RegConnectRegistry function.


The handle for a specified key should not be used after it has been closed, because it will no longer be valid. Key handles should not be left open any longer than necessary.

The RegCloseKey function does not necessarily write information to the registry before returning; it can take as much as several seconds for the cache to be flushed to the hard disk. If an application must explicitly write registry information to the hard disk, it can use the RegFlushKey function. RegFlushKey, however, uses many system resources and should be called only when necessary.

[RegOpenKey :]
[RegCloseKey :]
[RegCreateKey :]
[RegDeleteKey :]
Posted by 구차니

댓글을 달아 주세요