Skip to content

Commit

Permalink
Merge 1f07846 into 55fc8f1
Browse files Browse the repository at this point in the history
  • Loading branch information
merrickheley committed Nov 26, 2017
2 parents 55fc8f1 + 1f07846 commit 2b15d21
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions smartcard/CardMonitoring.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,8 @@ def deleteObserver(self, observer):
if _START_ON_DEMAND_:
if self.countObservers() == 0:
if self.rmthread != None:
self.rmthread.stop()
self.rmthread.join()
self.rmthread = None

def __str__(self):
Expand Down Expand Up @@ -207,6 +209,11 @@ def __init__(self, observable):
CardMonitoringThread.instance = \
CardMonitoringThread.__CardMonitoringThreadSingleton(observable)
CardMonitoringThread.instance.start()

def join(self, *args, **kwargs):
if self.instance:
self.instance.join(*args, **kwargs)
CardMonitoringThread.instance = None

def __getattr__(self, name):
if self.instance:
Expand Down

0 comments on commit 2b15d21

Please sign in to comment.