changeset c6b0570b4d1a in tryton:6.4
details: https://hg.tryton.org/tryton?cmd=changeset&node=c6b0570b4d1a
description:
        Never update counter label if widget has been removed

        On Windows it triggers a SIGSEGV.

        issue11395
        review423491003
        (grafted from d0764ce2fbebd20fdbcf6177fa51c6f9e3293755)
diffstat:

 tryton/gui/window/view_form/view/form_gtk/state_widget.py |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r fdd4c9f8131e -r c6b0570b4d1a 
tryton/gui/window/view_form/view/form_gtk/state_widget.py
--- a/tryton/gui/window/view_form/view/form_gtk/state_widget.py Fri Jul 01 
23:08:42 2022 +0200
+++ b/tryton/gui/window/view_form/view/form_gtk/state_widget.py Sun Jul 24 
23:32:56 2022 +0200
@@ -194,7 +194,7 @@
                         counter=counter, label=label))
 
     def _set_count(self, value, idx=0, current=None, counter=None, label=''):
-        if current != self._current and not self.get_parent():
+        if current != self._current or not self.get_parent():
             return
         try:
             count = value()

Reply via email to