mirror of
https://github.com/python/cpython.git
synced 2025-08-03 08:34:29 +00:00
#2879: rename _winreg to winreg.
This commit is contained in:
parent
2cb57a40b2
commit
38feaf0fef
20 changed files with 72 additions and 71 deletions
|
@ -5,7 +5,7 @@ import win32com.client.gencache
|
|||
import win32com.client
|
||||
import pythoncom, pywintypes
|
||||
from win32com.client import constants
|
||||
import re, string, os, sets, glob, subprocess, sys, _winreg, struct
|
||||
import re, string, os, sets, glob, subprocess, sys, winreg, struct
|
||||
|
||||
# Partially taken from Wine
|
||||
datasizemask= 0x00ff
|
||||
|
@ -376,9 +376,9 @@ class CAB:
|
|||
(r"Software\Microsoft\Win32SDK\Directories", "Install Dir"),
|
||||
]:
|
||||
try:
|
||||
key = _winreg.OpenKey(_winreg.HKEY_LOCAL_MACHINE, k)
|
||||
dir = _winreg.QueryValueEx(key, v)[0]
|
||||
_winreg.CloseKey(key)
|
||||
key = winreg.OpenKey(winreg.HKEY_LOCAL_MACHINE, k)
|
||||
dir = winreg.QueryValueEx(key, v)[0]
|
||||
winreg.CloseKey(key)
|
||||
except (WindowsError, IndexError):
|
||||
continue
|
||||
cabarc = os.path.join(dir, r"Bin", "cabarc.exe")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue