[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [stem/master] Invalidate cache on DNS_USELESS event
commit d42e9e1953ab5eac3677e16c51c1a4c28ef965ec
Author: Damian Johnson <atagar@xxxxxxxxxxxxxx>
Date: Sat Aug 4 15:23:05 2018 -0700
Invalidate cache on DNS_USELESS event
Irc discussion Dave partook in indicated that we should flush our cache when we
receive a DNS_USELESS event, not just EXTERNAL_ADDRESS.
https://trac.torproject.org/projects/tor/ticket/26129
---
stem/control.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/stem/control.py b/stem/control.py
index 19a8759d..7e1d1286 100644
--- a/stem/control.py
+++ b/stem/control.py
@@ -1078,7 +1078,7 @@ class Controller(BaseController):
self.add_event_listener(_confchanged_listener, EventType.CONF_CHANGED)
def _address_changed_listener(event):
- if event.action == 'EXTERNAL_ADDRESS':
+ if event.action in ('EXTERNAL_ADDRESS', 'DNS_USELESS'):
self._set_cache({'exit_policy': None})
self._set_cache({'address': None}, 'getinfo')
self._last_address_exc = None
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits