Issue #26200: Added Py_SETREF and replaced Py_XSETREF with Py_SETREF
in places where Py_DECREF was used.
diff --git a/Modules/_curses_panel.c b/Modules/_curses_panel.c
index 75bbb17..759b731 100644
--- a/Modules/_curses_panel.c
+++ b/Modules/_curses_panel.c
@@ -313,7 +313,7 @@
         return NULL;
     }
     Py_INCREF(temp);
-    Py_XSETREF(po->wo, temp);
+    Py_SETREF(po->wo, temp);
     Py_INCREF(Py_None);
     return Py_None;
 }