/[glsr]/trunk/harmonious/_sessionutils.py
Gentoo

Diff of /trunk/harmonious/_sessionutils.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 96 Revision 97
79 return False 79 return False
80 80
81 def has_session(self, sessionId): 81 def has_session(self, sessionId):
82 82
83 self.__lock.acquire() 83 self.__lock.acquire()
84 if sessionId in self.__store.keys(): 84 if self.__store.has_key(sessionId):
85 85
86 self.__lock.release() 86 self.__lock.release()
87 return True 87 return True
88 88
89 self.__lock.release() 89 self.__lock.release()
109 pass 109 pass
110 # self.__flush_file() 110 # self.__flush_file()
111 111
112 def set_persistent(self, sessionId, flag): 112 def set_persistent(self, sessionId, flag):
113 113
114 if self.has_session(sessionId):
114 self.__lock.acquire() 115 self.__lock.acquire()
115 self.__store[sessionId]['persistent'] = flag 116 self.__store[sessionId]['persistent'] = flag
116 self.__lock.release() 117 self.__lock.release()
117 118
118 def load_session(self, sessionId): 119 def load_session(self, sessionId):
119 120
120 if self.__type == 'ram': 121 if self.__type == 'ram':
121 122

Legend:
Removed from v.96  
changed lines
  Added in v.97

  ViewVC Help
Powered by ViewVC 1.1.20