Abhilash Raj pushed to branch master at GNU Mailman / Mailman Core
Commits:
a51fa501 by Abhilash Raj at 2022-01-28T20:56:50-08:00
Use list to create a copy of the dictionary keys.
Since it is possible to have dictionary changed during the iteration,
make a copy of the keys before iterating on them.
Fixes #724
- - - - -
ac57a6c5 by Abhilash Raj at 2022-01-29T16:54:50+00:00
Merge branch 'fix-runtime' into 'master'
Use list to create a copy of the dictionary keys.
Closes #724
See merge request mailman/mailman!953
- - - - -
2 changed files:
- src/mailman/bin/master.py
- src/mailman/docs/NEWS.rst
Changes:
=====================================
src/mailman/bin/master.py
=====================================
@@ -204,7 +204,7 @@ class PIDWatcher:
# asynchronous signals are involved, the dictionary's size could
# change during iteration. Iterate over a copy of the keys to avoid
# that.
- for pid in self._pids.keys():
+ for pid in list(self._pids):
yield pid
def add(self, pid, info):
=====================================
src/mailman/docs/NEWS.rst
=====================================
@@ -33,7 +33,8 @@ Bugs fixed
boolean attributes. (Closes #970)
* Fix a bug where loading a plugin which raises an exception in ``pre_hook``
can cause Mailman to crash trying to disable that plugin. (Closes #724)
-
+* Fix a bug where the ``PIDWatcher()`` iterates over internal dict while
+ it can be updated during that time. (Closes #724)
.. _news-3.3.5:
@@ -133,7 +134,7 @@ Bugs fixed
* Nonmember posts gated from usenet bypass nonmember moderation. (Closes #937)
* VERPed vacation responses and similar are no longer scored as bounces.
(Closes #939)
-* If a message is held by a ``HeaderMatchRule``, the header name is now
included
+* If a message is held by a ``HeaderMatchRule``, the header name is now
included
in the reason for hold. (Closes #785)
Command line
View it on GitLab:
https://gitlab.com/mailman/mailman/-/compare/f6dbbd50105bbf2edf92324480afbf20449b85a6...ac57a6c52f3e93bf1a639b61337d9914e022a848
--
View it on GitLab:
https://gitlab.com/mailman/mailman/-/compare/f6dbbd50105bbf2edf92324480afbf20449b85a6...ac57a6c52f3e93bf1a639b61337d9914e022a848
You're receiving this email because of your account on gitlab.com.
_______________________________________________
Mailman-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/mailman-checkins.python.org/
Member address: [email protected]