Account for the situation where the directory passed in is the binary diretory

but the libraries are in a parallel directory.
This commit is contained in:
Anthony Tuininga 2008-09-26 21:17:20 +00:00
parent 33a2280ad1
commit 2938d07b35
1 changed files with 7 additions and 0 deletions

View File

@ -93,6 +93,13 @@ def CheckOracleHome(directoryToCheck):
oracleLibDir = os.path.join(directoryToCheck, subDir)
oracleVersion = version
return True
dirName = os.path.dirname(directoryToCheck)
fileName = os.path.join(dirName, subDir, baseFileName)
if os.path.exists(fileName):
oracleHome = dirName
oracleLibDir = os.path.join(dirName, subDir)
oracleVersion = version
return True
oracleHome = oracleVersion = oracleLibDir = None
return False