diff options
| author | Rob Crittenden <rcritten@redhat.com> | 2008-05-13 10:59:37 -0400 |
|---|---|---|
| committer | Rob Crittenden <rcritten@redhat.com> | 2008-05-13 12:00:21 -0400 |
| commit | 3daa94ccc05d8d85de4309ee4e56a76bc435efc9 (patch) | |
| tree | 78337f68588fd3d8aa2b7d2871e79312c13d004e /ipa-admintools/ipa-adduser | |
| parent | b1cc4199fa152957aaabed1b22e8b828d054d9c6 (diff) | |
Catch name resolution errors coming from the socket module.
442650
Diffstat (limited to 'ipa-admintools/ipa-adduser')
| -rw-r--r-- | ipa-admintools/ipa-adduser | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ipa-admintools/ipa-adduser b/ipa-admintools/ipa-adduser index be0912e95..caff5a953 100644 --- a/ipa-admintools/ipa-adduser +++ b/ipa-admintools/ipa-adduser @@ -33,6 +33,7 @@ try: import ldap import getpass import errno + import socket except ImportError: print >> sys.stderr, """\ There was a problem importing one of the required Python modules. The @@ -268,6 +269,9 @@ except xmlrpclib.ProtocolError, e: except ipa.ipaerror.IPAError, e: print "%s" % (e.message) sys.exit(1) +except socket.error, e: + print e[1] + print "Re-run with -v flag for more details." except Exception, e: print "%s" % str(e) sys.exit(1) |
