Skip to content

Commit c8f0f09

Browse files
committed
fixed assert in XDecref in case _Py_IsFinalizing is not present
1 parent c2e207a commit c8f0f09

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/runtime.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,7 @@ internal static unsafe void XDecref(StolenReference op)
714714
{
715715
#if DEBUG
716716
Debug.Assert(op == null || Refcount(new BorrowedReference(op.Pointer)) > 0);
717-
Debug.Assert(_isInitialized || Py_IsInitialized() != 0 || _Py_IsFinalizing() == true);
717+
Debug.Assert(_isInitialized || Py_IsInitialized() != 0 || _Py_IsFinalizing() != false);
718718
#endif
719719
#if !CUSTOM_INCDEC_REF
720720
if (op == null) return;

0 commit comments

Comments
 (0)