Changeset 1516
- Timestamp:
- 10/17/08 16:59:32 (3 months ago)
- Files:
-
- wine-doors/trunk/src/application.py (modified) (3 diffs)
- wine-doors/trunk/src/wine.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
wine-doors/trunk/src/application.py
r1505 r1516 537 537 self.Parse() 538 538 539 allowed = [ "msiexec" ] 540 539 541 reg = re.compile("^HK") 540 542 if not self.app_pack['uninstall']: … … 544 546 elif self.app_pack['uninstall'].lower().startswith("c:"): 545 547 uninstaller = self.app_pack['uninstall'] 548 elif self.app_pack['uninstall'].lower().split(" ")[0] in allowed: 549 uninstaller = self.app_pack['uninstall'] 546 550 else: 547 551 uninstaller = self.pack_path + self.app_pack['uninstall'] … … 556 560 args = None 557 561 558 if os.path.isfile(uninstaller) or os.path.isfile( wine.ConvertPath(uninstaller) ): 562 if os.path.isfile(uninstaller) or \ 563 os.path.isfile( wine.ConvertPath(uninstaller) ) or \ 564 uninstaller.lower().split(" ")[0] in allowed : 559 565 self.status = wine.Execute(uninstaller, args) 560 566 else: wine-doors/trunk/src/wine.py
r1505 r1516 274 274 filefound = False 275 275 276 if executable == "regedit" and not argstring:277 return278 279 276 if not argstring: 280 277 argstring = "" 281 278 else: 282 279 argstring = " "+argstring 280 281 # hard coded list of things to "just let through" 282 allowed = [ "regedit", "winver", "msiexec" ] 283 283 284 284 # fix file:// URI's … … 291 291 oldcwd = os.getcwd() 292 292 os.chdir( os.path.expanduser( "~/" ) ) 293 293 294 294 # Various tests to locate the file, if we still fail return with an error 295 if not os.path.isfile(executable) and executable != "regedit" and executable != "winver":295 if not os.path.isfile(executable) and not executable.lower().split(" ")[0] in allowed: 296 296 log.Warn("Can't find executable %s, Assuming CD drive path" % executable) 297 297 cd = GetCDMountPoint() … … 309 309 310 310 # Determine the executable, and construct an executable command 311 if executable == "regedit": 312 executable = "C:\\windows\\regedit.exe" 313 elif executable == "winver": 311 if executable == "winver": 314 312 executable = "C:\\windows\\system32\\winver.exe" 313 elif executable.lower().split(" ")[0] in allowed: 314 run = executable 315 315 elif re.search("\.msi", executable): 316 316 run = "msiexec /i " + executable
