| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| Expand Up | @@ -232,5 +232,6 @@ public string ToString(string format, IFormatProvider formatProvider) | |
| } | ||
|
|
||
| public override TypeCode GetTypeCode() => TypeCode.Int64; | ||
| public override int GetHashCode() => ((PyObject)this).GetHashCode(); | ||
|
Comment thread
Copy link
Copy Markdown
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low QualitySame
Sorry, something went wrong.
All reactions
|
||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| Expand Up | @@ -83,8 +83,8 @@ internal static unsafe void DecrefTypeAndFree(StolenReference ob) | |
|
|
||
| var freePtr = Util.ReadIntPtr(type, TypeOffset.tp_free); | ||
| Debug.Assert(freePtr != IntPtr.Zero); | ||
| var free = (delegate* unmanaged[Cdecl]<StolenReference, void>)freePtr; | ||
| free(ob); | ||
| var free = (delegate* unmanaged[Cdecl]<ref StolenReference, void>)freePtr; | ||
| free(ref ob); | ||
|
Comment thread
Comment on lines
+86
to
+87
Copy link
Copy Markdown
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low QualityI think this is wrong. It does not say anywhere but I'd expect tp_free to take a reference to PyObject (e.g. PyObject*), not a reference to reference to it (e.g. not a PyObject**).
Sorry, something went wrong.
All reactions
Copy link
Copy Markdown
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low QualityAh, that's probably one reason for the crashes :)
Sorry, something went wrong.
All reactions
|
||
|
|
||
| Runtime.XDecref(StolenReference.DangerousFromPointer(type.DangerousGetAddress())); | ||
| } | ||
| Expand Down | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| ### New Rules | ||
|
|
||
| Rule ID | Category | Severity | Notes | ||
| --------|----------|----------|-------------------- | ||
| NoCopy99|Correction| Warning | N/A |
| Back | FazBrowse Home | New Git URL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low QualityThis looks like it would just stackoverflow
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.