diff --git a/hbd b/hbd index f98fee6..a1c4173 100755 --- a/hbd +++ b/hbd @@ -83,6 +83,14 @@ class Host: self.cmds = [] num += 1 + + # called when reloading class from pickle + def fixup(self): + try: + a=self.cmds + except: + self.cmds=[] + def getstate(self): return self.state @@ -744,6 +752,8 @@ if os.path.exists(PICKFILE): pickf.close() except: os.unlink(PICKFILE) + for h in hosts.keys(): + hosts[h].fixup() for h in drophosts: if h in hosts: # was: hosts.has_key(h): del hosts[h]