From d69c351cd76447b5bfe5813a4adfecfd921cd949 Mon Sep 17 00:00:00 2001 From: Narayan Desai Date: Fri, 14 Jul 2006 15:36:47 +0000 Subject: Cleanly handle profile assertion errors git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1939 ce84e21b-d406-0410-9b95-82705330c041 --- src/sbin/bcfg2 | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/sbin') diff --git a/src/sbin/bcfg2 b/src/sbin/bcfg2 index f88f41b29..33bef6147 100755 --- a/src/sbin/bcfg2 +++ b/src/sbin/bcfg2 @@ -159,7 +159,10 @@ class Client: proxy = Bcfg2.Client.Proxy.bcfg2() if self.setup['profile']: - proxy.AssertProfile(self.setup['profile']) + try: + proxy.AssertProfile(self.setup['profile']) + except xmlrpclib.Fault: + self.fatal_error("Failed to set client profile") try: probe_data = proxy.GetProbes() -- cgit v1.2.3-1-g7c22