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: endless loop in save #6800

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

fix: endless loop in save #6800

wants to merge 1 commit into from

Conversation

omniskop
Copy link

@omniskop omniskop commented Jan 20, 2024

  • Do only one thing
  • Non breaking API changes
  • Tested

What did this pull request do?

Save attempts to dereference an interface using reflect.Indirect this doesn't work as that is only intended for pointers.
This change stops it from trying to do that. Trying to do this will instead result in an error.

I don't think this should cause any breaking changes, but I don't know why this code was written like.

This would close Issue #6799 but if another solution for the problem would be preferred feel free to close this pull request.

User Case Description

While it might not be a supported case to call Save with a pointer to an interface it should not cause an endless loop.

Copy link
Member

@a631807682 a631807682 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for your contribution, we are sure this is a bug and it comes from 0729261, can you add some tests for it?

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

Successfully merging this pull request may close these issues.

None yet

2 participants