-
Notifications
You must be signed in to change notification settings - Fork 8.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FAB-6712] Fix re-used pointer in proto txlation
The protolator framework depends on anotations made in go code to the proto messages to determine how to properly marshal and unmarshal opaque fields. This code is supposed to return a new proto message in response to a call for a particular opaque field. However, for the Envelope data field, the same pointer (and not a new proto message) was returned every time. This could cause data from a previous translation to persist into subsequent ones, causing unusual failures. This CR fixes the function to return a clone of the pointer, rather than the pointer directly. This CR also fixes a log message bug in the configtxupdate example, as well as a statically referenced filename that should have been pulled from an env variable. It also annotates the signature header with the correct opaque types which was required for debugging this problem but is generally useful. Change-Id: I44c48b01d0095c7175e6e07e70d464c6d39f2f21 Signed-off-by: Jason Yellick <[email protected]>
- Loading branch information
Jason Yellick
committed
Oct 20, 2017
1 parent
9cea8c7
commit 70c467f
Showing
4 changed files
with
18 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters