mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-26 18:18:25 +00:00
Changed iteration to list comprehension in order to prevent "RuntimeError: dictionary changed size during iteration"
This commit is contained in:
parent
49e10d7cc2
commit
b456c3afa1
@ -18,6 +18,7 @@ Unreleased: mitmproxy next
|
||||
* mitmweb: "New -> File" menu option has been renamed to "Clear All" (@yogeshojha)
|
||||
* Add new MapRemote addon to rewrite URLs of requests (@mplattner)
|
||||
* Add support for HTTP Trailers to the HTTP/2 protocol (@sanlengjingvv and @Kriechi)
|
||||
* Fix certificate runtime error during expire cleanup (@gorogoroumaru)
|
||||
|
||||
* --- TODO: add new PRs above this line ---
|
||||
|
||||
|
@ -173,9 +173,7 @@ class CertStore:
|
||||
self.expire_queue.append(entry)
|
||||
if len(self.expire_queue) > self.STORE_CAP:
|
||||
d = self.expire_queue.pop(0)
|
||||
for k, v in list(self.certs.items()):
|
||||
if v == d:
|
||||
del self.certs[k]
|
||||
self.certs = {k: v for k, v in self.certs.items() if v != d}
|
||||
|
||||
@staticmethod
|
||||
def load_dhparam(path):
|
||||
|
Loading…
Reference in New Issue
Block a user