genhomedircon.py: Fix top-level exception handling.

Fixes errors like this:

Traceback (most recent call last):
  File "support/genhomedircon.py", line 490, in <module>
    errorExit("Options Error " + error)
TypeError: Can't convert 'GetoptError' object to str implicitly

Signed-off-by: Chris PeBenito <Christopher.PeBenito@microsoft.com>
This commit is contained in:
Chris PeBenito 2019-03-15 09:25:00 -04:00
parent 60b8e08f4f
commit 0af99256c6
1 changed files with 2 additions and 6 deletions

View File

@ -486,9 +486,5 @@ try:
selconf=selinuxConfig(directory, setype, usepwd)
selconf.write()
except getopt.error as error:
errorExit("Options Error " + error)
except ValueError as error:
errorExit("ValueError " + error)
except IndexError:
errorExit("IndexError")
except Exception as error:
errorExit(error)