Skip to content
New issue

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

fix swig ownership when assigning to struct pointer field #3139

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

mdouze
Copy link
Contributor

@mdouze mdouze commented Nov 22, 2023

Summary: When faiss is called from SWIG, it is usually assumed that Python will do all the memory management, therefore assigning to a pointer in C++ should not transfer ownerhsip (default SWIG behavior). This diff fixed that.

Differential Revision: D51529085

Summary: When faiss is called from SWIG, it is usually assumed that Python will do all the memory management, therefore assigning to a pointer in C++ should not transfer ownerhsip (default SWIG behavior). This diff fixed that.

Differential Revision: D51529085
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D51529085

@mdouze
Copy link
Contributor Author

mdouze commented Nov 22, 2023

hopefully this will finally fix #2996

@junjieqi
Copy link
Contributor

@mdouze do we still need this one?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants