summaryrefslogtreecommitdiffstats
path: root/ipalib/cli.py
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2008-11-03 17:38:05 -0500
committerRob Crittenden <rcritten@redhat.com>2008-11-03 17:38:05 -0500
commitf1314806434b9226f8a7722675b060bdf574c455 (patch)
tree5de794202b5c7cecd25de3848418b1740d825897 /ipalib/cli.py
parenta97f5d76d1f9caa9dee30b67dc6b68d436a334c2 (diff)
downloadfreeipa.git-f1314806434b9226f8a7722675b060bdf574c455.tar.gz
freeipa.git-f1314806434b9226f8a7722675b060bdf574c455.tar.xz
freeipa.git-f1314806434b9226f8a7722675b060bdf574c455.zip
Move socket errors from the XML-RPC plugin to the client
Diffstat (limited to 'ipalib/cli.py')
-rw-r--r--ipalib/cli.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/ipalib/cli.py b/ipalib/cli.py
index 8cf8d304..d7288154 100644
--- a/ipalib/cli.py
+++ b/ipalib/cli.py
@@ -25,6 +25,7 @@ import re
import sys
import code
import optparse
+import socket
import frontend
import errors
@@ -377,6 +378,9 @@ class CLI(object):
if callable(cmd.output_for_cli):
cmd.output_for_cli(ret)
return 0
+ except socket.error, e:
+ print e[1]
+ return 1
except errors.GenericError, err:
code = getattr(err,'faultCode',None)
faultString = getattr(err,'faultString',None)