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 buffer reuse #624

Closed
wants to merge 3 commits into from
Closed

Fix buffer reuse #624

wants to merge 3 commits into from

Conversation

apelisse
Copy link
Contributor

@apelisse apelisse commented Sep 9, 2019

Alternative fix to issue #619. I've used the test built in #621. Not sure which one is best.

@apelisse
Copy link
Contributor Author

apelisse commented Sep 9, 2019

Also, I would have to regenerate the pb.go test files

@apelisse
Copy link
Contributor Author

apelisse commented Sep 9, 2019

OK This should be working now, I've undid the changes that I had done to XXX_Marshal, and used a different interface instead, I think this should be good.

}

}
if m, ok := pb.(reverseMarshaler); ok {
Copy link
Contributor

Choose a reason for hiding this comment

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

Currently I think I would prefer too rather not adding another interface here and keep calling the XXX methods here.
With the direct calling we will skip the p.deterministic setting on the buffer.

Copy link
Contributor

Choose a reason for hiding this comment

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

I do have a safer approach here:
#627
Keeping the current interfaces/flow.

@jmarais
Copy link
Contributor

jmarais commented Oct 11, 2019

In favor of: #627

@jmarais jmarais closed this Oct 11, 2019
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