Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit fa47957

Browse files
committed
fixup! fixup! More changes to use BorrowedReference and NewReference
1 parent d5fcfa4 commit fa47957

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/runtime/runtime_data.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ internal static void Stash()
8686

8787
ClearCLRData();
8888
NewReference capsule = PyCapsule_New(mem, null, IntPtr.Zero);
89-
PySys_SetObject("clr_data", capsule);
89+
PySys_SetObject("clr_data", capsule.DangerousGetAddress());
9090
// Let the dictionary own the reference
9191
capsule.Dispose();
9292
}

0 commit comments

Comments
 (0)